Jump to content

Tankman

Members
  • Posts

    11
  • Joined

  • Last visited

About Tankman

  • Birthday 08/19/1983

Profile Information

  • Location
    Vienna, Austria

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Tankman's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Hello Guys I wonder if anybody could help me to figure this out. I would like to receive the Power Event for when my monitor goes into standby. It should be GUID_MONITOR_POWER_ON and Raik posted the way to get it. Unfortunately I just can't figure out how to use his code to get what I need. Please help. Thanks!
  2. Thank you guiness Still not what I needed. If I could just figure out on how to retrieve GUID_MONITOR_POWER_ON.
  3. Thank you Xenobiologist for the quick answer. I have seen both scripts b4 as I was trying to search for a solution to my problem. The first script shows a way to turn the monitor off or on but I need a script to check if the monitor is currently off or on. I was already testing the second script before my original posting. The field "Availability" of the monitor properties seemed to be just what I was looking for. Unfortunately the status never changed when the monitor got into standby and back again. But still thanks for your help.
  4. Hi Guys I need a script for one of my programs that checks the current monitor status. In specific if my system turned my monitor off. On MSDN I found the following System Power Event GUID_MONITOR_POWER_ON http://msdn.microsoft.com/en-us/library/aa373195%28v=VS.85%29.aspx Unfortunately I am too much of a beginner at scripting that I just don't know how to get the status of that event. I hope somebody here can help me. Greetings, Tankman
  5. Sorry it took me so long to get back to you guys. I played around with IsAdmin() and found out that the function works even when UAC is turned off. I decided against trying to run the script again with RunAs() and just check if the process is running with Adminrights, if not then I write out an error with MsgBox(). To sum everything up... I created a script that was compiled with SciTE using the AU3Wrapper-Setting #AutoIt3Wrapper_Res_requestedExecutionLevel=requireAdministrator and a simple code that checks for Adminrights like If Not Isadmin() Then MsgBox(48,"Error", "Error") Exit EndIf I am satisfied with the way it behaves now, although a properly working #RequireAdmin would still be nice.
  6. Hi Stefan Thanks for your post. I never tried it with IsAdmin() cause I read in another forum post that the function doesn't work when UAC is disabled. But I will give it a try tomorrow and report back if it worked.
  7. Well, that teaches me to also search for open bug reports and not only in the forum :-) Thanks for the hint MHz. In the meantime I found a little workaround. When I compile my Script with SciTE and set the Au3Wrapper-Setting "Execution Level" to "Requireadministrator" it works much better. The script doesn't get elevated to Admin under User-credentials when UAC is turned off, but at least it doesn't create an executing loop. Of course it would be most perfect if Users get asked for Adminrights even when UAC is turned off, but it seems that isn't possible. Thanks again.
  8. Just wanted to say that I had time today to test out my problem on some other operating systems. It was the same at Windows 7 Professional x32 and Windows Vista Business x32. I am curios if I am just unable to install Windows several times or if this is really a bug. Could somebody please try to reproduce this and tell me how it worked? All you have to do is create an account with user permissions, deactivate UAC (restart afterwards, of course) and then run the following script #RequireAdmin MsgBox(0, "Test", "Test") I don't get the MessageBox. As soon as I run the script I see the hourglass flashing constantly and when I check the running processes in the Task Manager I see my script starting and stopping all the time. Again, I have no problem whatsoever when I run the script as an Administrator (naturally) or when UAC is turned on.
  9. Hi there AutoIt-Community Long time reader (thanks for all the help), first time writer here. I have a problem with #Requireadmin in my script. It happens when u execute it with user privileges and UAC is turned off. I narrowed it down to #Requireadmin, cause the same problem appears when I write a simple script like #RequireAdmin MsgBox(0, "Test", "Test") This script causes Autoit to spawn itself in a loop over and over again. I couldn't even kill the process. I had to restart to make it stop. Once I comment #Requireadmin out it works without a problem. The script works fine with administrator privileges or when UAC is turned on, then it correctly asks me for admin credentials under a user account. I am using AutoIt v3.3.6.0 (also tried it with v3.3.4.0) under Windows 7 Professional x64. I would be very thankful for any help.
×
×
  • Create New...