BobiusMaximus 0 Posted December 3, 2006 (edited) Is there a way to make the screen go black for a second with autoit and then come back on? If there is, please enlighten me as to how -Bob Edited December 3, 2006 by BobTheLeetHaxx0r Hide BobiusMaximus's signature Hide all signatures Photoshop User and Noob AutoIt user. Share this post Link to post Share on other sites
Kreatorul 0 Posted December 3, 2006 Unplug the monitor's power cord and then plug it back in )) This should do it Share this post Link to post Share on other sites
BobiusMaximus 0 Posted December 3, 2006 With autoit *Edits First Post* -Bob Hide BobiusMaximus's signature Hide all signatures Photoshop User and Noob AutoIt user. Share this post Link to post Share on other sites
Kreatorul 0 Posted December 3, 2006 Create a big black gui and put a little sleep Share this post Link to post Share on other sites
BobiusMaximus 0 Posted December 3, 2006 Create a big black gui and put a little sleepSo there is no function that does it? Hide BobiusMaximus's signature Hide all signatures Photoshop User and Noob AutoIt user. Share this post Link to post Share on other sites
Kreatorul 0 Posted December 3, 2006 #include <GuiConstants.au3> $width = Width of your screen $height = Height of your screen GuiCreate("black screen", $width, $height, 0, 0, $WS_POPUP) GuiSetState() GuiSetBkColor(000000) Sleep(1000) Share this post Link to post Share on other sites
BobiusMaximus 0 Posted December 3, 2006 What if you want to include it in a program, so to come up, then go away, how would you do that? Hide BobiusMaximus's signature Hide all signatures Photoshop User and Noob AutoIt user. Share this post Link to post Share on other sites
Kreatorul 0 Posted December 3, 2006 #include <GuiConstants.au3> Func GoBlack() $width = Width of your screen $height = Height of your screen GuiCreate("black screen", $width, $height, 0, 0, $WS_POPUP) GuiSetState() GuiSetBkColor(000000) Sleep(1000) EndFunc And just call the function when you want Share this post Link to post Share on other sites
BobiusMaximus 0 Posted December 3, 2006 (edited) I'm getting confused here, how do you call a function? -Bob Edit: Well, I know how to call a function with a hot key, but I just want it to happen during the program. Edit 2: Actually, I have an idea. Edit 3: How Do I close it so I can call it again if I want? Edited December 3, 2006 by BobTheLeetHaxx0r Hide BobiusMaximus's signature Hide all signatures Photoshop User and Noob AutoIt user. Share this post Link to post Share on other sites
Kreatorul 0 Posted December 3, 2006 (edited) There is something called helpfile but #include <GuiConstants.au3> MsgBox(0, "Func", "Now I'm gonna call a function") GoBlack() MsgBox(0, "End", "I called a function") Func GoBlack() $width = Width of your screen $height = Height of your screen GuiCreate("black screen", $width, $height, 0, 0, $WS_POPUP) GuiSetState() GuiSetBkColor(000000) Sleep(1000) EndFunc Edited December 3, 2006 by Kreatorul Share this post Link to post Share on other sites
theguy0000 2 Posted December 3, 2006 there is a way to turn the monitor off then on, and it is used in Office Poltergeist...one moment please....... Hide theguy0000's signature Hide all signatures The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Share this post Link to post Share on other sites
theguy0000 2 Posted December 3, 2006 (edited) Ok, put this at the top of your script: Opt("WinTitleMatchMode", 4) Global $DllHWND = WinGetHandle("classname=Progman")oÝ÷ Ù8Z¶¬¶(jÛazÚ)N§Êj{¬zØb²Ú-º¹â¶ßjëh×6DllCall("user32.dll", "int", "SendMessage", "hwnd", $DllHWND, "int", 274, "int", 61808, "int", 2) There you go Edited December 3, 2006 by theguy0000 Hide theguy0000's signature Hide all signatures The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Share this post Link to post Share on other sites
BobiusMaximus 0 Posted December 3, 2006 Ok, put this at the top of your script: Opt("WinTitleMatchMode", 4) Global $DllHWND = WinGetHandle("classname=Progman")oÝ÷ Ù8Z¶¬¶(jÛazÚ)N§Êj{¬zØb²Ú-º¹â¶ßjëh×6DllCall("user32.dll", "int", "SendMessage", "hwnd", $DllHWND, "int", 274, "int", 61808, "int", 2) There you go Godleh! Thanks both of you -Bob Hide BobiusMaximus's signature Hide all signatures Photoshop User and Noob AutoIt user. Share this post Link to post Share on other sites
nitekram 68 Posted December 3, 2006 Ok, put this at the top of your script: Opt("WinTitleMatchMode", 4) Global $DllHWND = WinGetHandle("classname=Progman")oÝ÷ Ù8Z¶¬¶(jÛazÚ)N§Êj{¬zØb²Ú-º¹â¶ßjëh×6DllCall("user32.dll", "int", "SendMessage", "hwnd", $DllHWND, "int", 274, "int", 61808, "int", 2)oÝ÷ Ù8^쨺 ?ªê-xz0r¶¬Â䱫¢+Ø(í±¸Íɸ)=ÁÐ ÅÕ½Ðí]¥¹Q¥Ñ±5Ñ¡5½ÅÕ½Ðì°Ð¤)±½°ÀÌØí±±!]9ô]¥¹Ñ!¹± ÅÕ½Ðí±Í͹µõAɽµ¸ÅÕ½Ðì¤()±± ±° ÅÕ½ÐíÕÍÈÌȹ±°ÅÕ½Ðì°ÅÕ½Ðí¥¹ÐÅÕ½Ðì°ÅÕ½ÐíM¹5ÍÍÅÕ½Ðì°ÅÕ½Ðí¡Ý¹ÅÕ½Ðì°ÀÌØí±±!]9°ÅÕ½Ðí¥¹ÐÅÕ½Ðì°ÈÜаÅÕ½Ðí¥¹ÐÅÕ½Ðì°ØÄàÀà°ÅÕ½Ðí¥¹ÐÅÕ½Ðì°È¤()M±À ÄÔÀÀÀ¤()±± ±° ÅÕ½ÐíÕÍÈÌȹ±°ÅÕ½Ðì°ÅÕ½Ðí¥¹ÐÅÕ½Ðì°ÅÕ½ÐíM¹5ÍÍÅÕ½Ðì°ÅÕ½Ðí¡Ý¹ÅÕ½Ðì°ÀÌØí±±!]9°ÅÕ½Ðí¥¹ÐÅÕ½Ðì°ÈÜаÅÕ½Ðí¥¹ÐÅÕ½Ðì°ØÄàÀà°ÅÕ½Ðí¥¹ÐÅÕ½Ð찴Ĥ(oÝ÷ Ø Ý¶¬v¬mzË^u¨v§w +Çâ®Ëmg¨½êò¢Ø^®Ø¦zØ^±ÊÞz{n®{iÉ()åzË-©÷±ç(Û'z÷«)ݲ¢wÇzËbµ©Ý±ç°«mìwb¶+÷Þéíy§!¶)!Ƨkzèv綺®¶s`£¶&Æ6¶Vâ67&VVà¤÷BgV÷CµvåFFÆTÖF6ÖöFRgV÷C²ÂB¤vÆö&Âb33c´FÆÄtäBÒvävWDæFÆRgV÷C¶6Æ76æÖSÕ&övÖâgV÷C² ¤×6t&÷b33²b33²Âb33²b33²Âb33´vöærFòGW&â67&VVâöfbb33²³²F22FRöæÇFffW&Væ6Rââà ¤FÆÄ6ÆÂgV÷C·W6W#3"æFÆÂgV÷C²ÂgV÷C¶çBgV÷C²ÂgV÷Cµ6VæDÖW76vRgV÷C²ÂgV÷C¶væBgV÷C²Âb33c´FÆÄtäBÂgV÷C¶çBgV÷C²Â#sBÂgV÷C¶çBgV÷C²ÂcÂgV÷C¶çBgV÷C²Â" ¥6ÆVWS ¤FÆÄ6ÆÂgV÷C·W6W#3"æFÆÂgV÷C²ÂgV÷C¶çBgV÷C²ÂgV÷Cµ6VæDÖW76vRgV÷C²ÂgV÷C¶væBgV÷C²Âb33c´FÆÄtäBÂgV÷C¶çBgV÷C²Â#sBÂgV÷C¶çBgV÷C²ÂcÂgV÷C¶çBgV÷C²ÂÓ Hide nitekram's signature Hide all signatures 2¢All by me:"Sometimes you have to go back to where you started, to get to where you want to go." "Everybody catches up with everyone, eventually" "As you teach others, you are really teaching yourself." From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow." WIKI | Tabs; | Arrays; | Strings | Wiki Arrays | How to ask a Question | Forum Search | FAQ | Tutorials | Original FAQ | ONLINE HELP | UDF's Wiki | AutoIt PDF AutoIt Snippets | Multple Guis | Interrupting a running function | Another Send StringRegExp | StringRegExp Help | RegEXTester | REG TUTOR | Reg TUTOT 2AutoItSetOption | Macros | AutoIt Snippets | Wrapper | Autoit Docs SCITE | SciteJump | BB | MyTopics | Programming | UDFs | AutoIt 123 | UDFs Form | UDFLearning to script | Tutorials | Documentation | IE.AU3 | Games? | FreeSoftware | Path_Online | Core Language Programming TipsExcel ChangesControlHover.UDFGDI_PlusDraw_On_ScreenGDI BasicsGDI_More_BasicsGDI RotateGDI GraphGDI CheckExistingItemsGDI TrajectoryReplace $ghGDIPDll with $__g_hGDIPDllDLL 101?Array via ObjectGDI SwimlaneGDI Plus French 101 SiteGDI Examples UEZGDI Basic ClockGDI DetectionTernary operator Share this post Link to post Share on other sites
theguy0000 2 Posted December 3, 2006 that's wierd...it works every time in office poltergeist...although of course they use variables, but that should make no difference... here is the func directly from office poltergeist: func screenFlicker() Opt("WinTitleMatchMode", 4) $WM_SYSCommand = 274 $SC_MonitorPower = 61808 $Power_On = -1 $Power_Off = 2 $X = 1 $HWND = WinGetHandle("classname=Progman") DllCall("user32.dll", "int", "SendMessage", "hwnd", $HWND, "int", $WM_SYSCommand, "int", $SC_MonitorPower, "int", $Power_Off) DllCall("user32.dll", "int", "SendMessage", "hwnd", $HWND, "int", $WM_SYSCommand, "int", $SC_MonitorPower, "int", $Power_On) endFunc Hide theguy0000's signature Hide all signatures The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN Share this post Link to post Share on other sites
daslick 2 Posted April 19, 2007 or you could use ON = DllCall("user32.dll", "int", "SendMessage", "hwnd", WinGetHandle("classname=Progman"), "int", 274, "int", 61808, "int", 2) OFF = DllCall("user32.dll", "int", "SendMessage", "hwnd", WinGetHandle("classname=Progman"), "int", 274, "int", 61808, "int", -1) Share this post Link to post Share on other sites