Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 7 of 7
  1. #1
    Join Date
    Aug 2006
    Posts
    355

    Close internet conection and power off monitor??

    Hi

    i like to know how scrip to me to be able to disconnect the connection to Internet

    also as it is possible to be made to power off the monitor

    thanks

  2. #2
    Join Date
    Jan 2000
    Posts
    2,002
    Try this:

    Code:
    strMessage = "Please unplug your network cable, turn off your monitor, and click OK to continue.";
    Dialog.Message("Instructions",strMessage);
    just kidding.

    There is no way to do those things that are built into AMS. However, if you find a DLL or executable that does them you can call them from AMS.

  3. #3
    Join Date
    Feb 2007
    Location
    Australia
    Posts
    201
    1. Download NirCmd is a small command-line utility
    http://www.nirsoft.net/utils/nircmd.html

    2. install this in windows dir (just one file)
    OR (use it with your project to copy the file to windows folder)

    File.Copy("AutoPlay\\Docs\\nircmd.exe", "C:\\windows\\", true, true, false, true, nil);

    3. create batch file for each command eg..
    @echo off
    nircmd.exe monitor off

    4. use the batch file to each button click
    result = File.Run("AutoPlay\\Docs\\Monitor_Off.bat", "", "", -1 , true);

    Maybe there is other easier way but I only know this way, sorry if i m wrong.

    If there is any other way I m interested to know too.

  4. #4
    Join Date
    May 2007
    Posts
    52
    Thanks you, nals, the instructive was very usefull for me.. thanks!!


    -*-

    Sorry for my bad english.. im learning :P!

    bye

  5. #5
    Join Date
    May 2006
    Posts
    5,380
    here is a dll to turn off/standby the monitor, you can also invoke the users default screen saver
    Last edited by RizlaUK; 02-01-2009 at 11:35 AM.
    Open your eyes to Narcissism, Don't let her destroy your life!!

  6. #6
    Join Date
    Oct 2006
    Posts
    209

    Thumbs up thanx

    RiszlaUK brilliant idea. thanx

  7. #7
    Join Date
    Nov 2006
    Posts
    64

    Smile

    Last night I made an example of NirCmd, it might be useful for some people!

    Link Here!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts