|
2
|
DonationCoder.com Software / DC Member Programs and Projects / Re: LAN Speaker Control. :)
|
on: June 19, 2011, 10:35:51 AM
|
Here are the source codes as promised.
Nicely documented application! Can I use this to turn OFF my neighbour's speakers? Haha, actually if you can install the server on their comp, and get on their network, yes.... Even better, install the server, crack on to their router and set it to port forward 8571.. connect (from any internet connection), and voila. speaker and music control 
|
|
|
|
|
5
|
DonationCoder.com Software / DC Member Programs and Projects / LAN Speaker Control. :)
|
on: June 18, 2011, 05:20:48 PM
|
Situation/problem - you have some monster speakers hooked up to a desktop, but want to control the speakers from your laptop in the kitchen/upstairs etc. Solution - "AHK Remote" inspired idea - modified to work for my personal needs/housemates needs - with (basic) support for youtube, itunes. Screenshot/Explanation Requirements:ITunes. Slight configuration (Specify location of your songs, ip address of host machine) Mozilla Firefox (modify if path is different than mine, likely unless running Win 7. 64 bit.) Source code coming shortly, just have to clean it up a bit.
|
|
|
|
|
10
|
DonationCoder.com Software / Coding Snacks / Re: Run a bat-file on system shutdown
|
on: August 27, 2009, 11:12:56 AM
|
I'm looking for a application that can run a bat-file when Windows Vista is going to shutdown/restart. Does a application like this exist or would anyone like to create it?  here. it will run any program just edit the settings.ini file. to make the program run on startup, place a shortcut (not a copy of the program) to your startup folder. program attached!
|
|
|
|
|
11
|
DonationCoder.com Software / Coding Snacks / Re: IDEA: Double-click makes a new folder
|
on: August 27, 2009, 11:11:11 AM
|
|
I wrote it for windows Xp, sorry I don't have a vista machine to work with.
Boliboli, about your comment; You need to change your folder options so only the name of the folder is shown in the window's title I believe. I deleted the source long ago so I'm not sure but give that a try.
For me I was able to use the script in any folder with no problems, but my computer is also the computer the program was designed for :/
|
|
|
|
|
13
|
DonationCoder.com Software / Coding Snacks / Re: IDEA: Double-click makes a new folder
|
on: February 13, 2009, 02:41:25 PM
|
|
The delay of your double-click isn't relevant, it shouldn't have any effect.
Nothing should be taking you to the folder above because the only keystrokes that get sent to the explorer window are {AppsKey} (opens the right click menu) w (selects New>) and {enter} (selects new folder)
I can make it so you can double click slower if needed.
The context menu shouldn't show for more than 1/4 of a second. I can try increasing the delays in the script if you think your computer is slow. (The time between opening the context menu and sending the keystrokes - if your computer lags when right clicking, the script won't correctly create a new folder - I might try a new approach later)
|
|
|
|
|
14
|
DonationCoder.com Software / Coding Snacks / Re: IDEA: Double-click makes a new folder
|
on: February 12, 2009, 02:34:24 PM
|
|
That's weird, it worked fine for me. If your computer has some lag, maybe increasing the delay in the script will help. Have you tried both with and without the Config.txt file in the script's directory?
Try both and let me know the results and a detail on exactly what happens when you try the double clicking.
I'll try to modify the script's delay if needed.
|
|
|
|
|
15
|
DonationCoder.com Software / Coding Snacks / Re: IDEA: Double-click makes a new folder
|
on: February 10, 2009, 03:29:45 PM
|
|
Compiled script uploaded. - The file name is selected after it is created so you can easily rename it - You can choose if you want the script to create text files or folders (text files are created by default - see the Config.txt file thats in the zip)
Sorry but I couldn't figure out a way to work with the desktop (wasn't sure how to detect if a file was or wasn't selected on the desktop)
|
|
|
|
|
16
|
DonationCoder.com Software / Coding Snacks / Re: [REQUEST] Review "Mr. Ping"
|
on: December 05, 2008, 01:48:37 PM
|
[ copy or print] If ConnectedToInternet() { Msgbox, An internet connection is currently detected.`nPress OK to exit the program. ExitApp } Else { Msgbox, An internet connection was not detected.`nPress OK to exit the program. ExitApp } ConnectedToInternet(flag=0x43) { Return DllCall("Wininet.dll\InternetGetConnectedState", Str,flag, Int,0 ) }
|
|
|
|
|
18
|
DonationCoder.com Software / Post New Requests Here / Re: IDEA: Draw on your desktop [Solution]
|
on: June 29, 2008, 09:09:07 PM
|
[ copy or print] CoordMode, Mouse, Screen Black = 000000 Green = 008000 Silver = C0C0C0 Lime = 00FF00 Gray = 808080 Olive = 808000 White = FFFFFF Yellow = FFFF00 Maroon = 800000 Navy = 000080 Red = FF0000 Blue = 0000FF Purple = 800080 Teal = 008080 Fuchsia = FF00FF Aqua = 00FFFF hh := A_ScreenHeight - 51 ww := A_ScreenWidth / 3 ColorChoice = Black LineWidth = 11 xpos=0 ypos=0 word= Gui 2: Color, black Gui 2: Add, Button, Default x-100 y1 gokbt, Gui 2: +LastFound +AlwaysOnTop +ToolWindow -Caption Gui 2: Add, Edit, vword x20 y1 w%ww%, Gui 2: Add, DropDownList, w80 x+20 y1 choose2 vColorChoice gchange, Aqua|Black|Blue|Fuchsia|Gray|Green|Lime|Maroon|Navy|Olive|Purple|Red|Silver|Teal|White|Yellow| Gui 2: Add, DropDownList, w40 x+20 y1 choose4 vLineWidth gchange2, 8|9|10|11|12|14|16|18|20|22|24|26|28|36|48|72| Gui 2: Show, x-1 y%hh% w%A_ScreenWidth% h22 Gui, 1:+LastFound +AlwaysOnTop Gui, 1:-Caption Gui, 1:Color, FF0000 WinSet, TransColor, FF0000 GuiHwnd := WinExist() Gui, 1:Show Gui, 1:Maximize SetTimer, DrawLine, 100 return okbt: Gui 2: Submit, NoHide StringLen, length, ww Send {Ctrl down} Send {a} Send {Ctrl up} Send {del} fontsize := LineWidth * 3 MouseGetPos, xpos, ypos Gui 3: Destroy Gui 3: Color, EEAA99 Gui 3: +LastFound +AlwaysOnTop +ToolWindow -Caption WinSet, TransColor, EEAA99 gui 3: font, s%fontsize% C%ColorChoice%, Verdana Gui 3: Add, Text, x1 y1, %word% Gui 3: Show, x%xpos% y%ypos% w%A_ScreenWidth% length= return DrawLine: GetKeyState, state, LButton GetKeyState, state2, Ctrl MouseGetPos, M_x, M_y if state = D if state2 = D { sleep 25 MouseGetPos, M_x2, M_y2 Canvas_DrawLine(GuihWnd, M_x, M_y, M_x2, M_y2, LineWidth, %ColorChoice%) loop 30 { GetKeyState, state, LButton GetKeyState, state2, Ctrl if state = U { break } else if state2 = U { break } sleep 25 MouseGetPos, M_x3, M_y3 Canvas_DrawLine(GuihWnd, M_x3, M_y3, M_x2, M_y2, LineWidth, %ColorChoice%) sleep 25 MouseGetPos, M_x2, M_y2 Canvas_DrawLine(GuihWnd, M_x3, M_y3, M_x2, M_y2, LineWidth, %ColorChoice%) } } return Canvas_DrawLine(hWnd, p_x1, p_y1, p_x2, p_y2, p_w, p_color) ; r,angle,width,color) { p_x1 -= 1, p_y1 -= 1, p_x2 -= 1, p_y2 -= 1 hDC := DllCall("GetDC", UInt, hWnd) hCurrPen := DllCall("CreatePen", UInt, 0, UInt, p_w, UInt, Convert_BGR(p_color)) DllCall("SelectObject", UInt,hdc, UInt,hCurrPen) DllCall("gdi32.dll\MoveToEx", UInt, hdc, Uint,p_x1, Uint, p_y1, Uint, 0 ) DllCall("gdi32.dll\LineTo", UInt, hdc, Uint, p_x2, Uint, p_y2 ) DllCall("ReleaseDC", UInt, 0, UInt, hDC) ; Clean-up. DllCall("DeleteObject", UInt,hCurrPen) } Convert_BGR(RGB) { StringLeft, r, RGB, 2 StringMid, g, RGB, 3, 2 StringRight, b, RGB, 2 Return, "0x" . b . g . r } return change: Gui 2: submit Gui 2: Color, %ColorChoice% Gui 2: Show, x-1 y%hh% w2000 h22 return change2: Gui 2: submit Gui 2: Show, x-1 y%hh% w2000 h22 return esc::exitapp ^r:: WinSet, Redraw,, ahk_id %GuiHwnd% Gui 3: Cancel return (Not my work)
|
|
|
|
|
23
|
DonationCoder.com Software / Post New Requests Here / Re: Silly Idea? A program that counts out loud
|
on: August 23, 2007, 05:49:43 PM
|
Well, heres the version I finished a few days ago [ copy or print] #NoTrayIcon #SingleInstance, Force ;SetTimer, RealTime, 1000 Active = False Count = 0 Gui, Add, Button, w100 h25 gStart vStartWp, Start Gui, Add, Button, w100 h25 yp xp+102 gPause, Pause Gui, Add, Button, w100 yp xp+102 h25 gStop, Stop Gui, Add, Text, vCountWp x10 w300 , Current Number: %Count% ;Gui, Add, Text, vCountSWp x10 w300 , Actual Elapsed Seconds: 0 Gui, +AlwaysOnTop Gui, Show return Stop: !s:: BreakLoop = True Count = 0 GuiControl,,CountWp,Current Number: 0 (Stopped) GuiControl,,StartWp,Start SoundBeep Active = False return Pause: !p:: BreakLoop = True GuiControl,,StartWp,Resume SoundBeep Active = False GuiControl,,CountWp,Current Number: %Count% (Paused) return Start: GuiControl,,StartWp,Start Active = True BreakLoop = False SetTimer, CountTime, 1000 return CountTime: If BreakLoop = True { SetTimer, CountTime, Off Active = False } If Active = False return Count += 1 GuiControl,,CountWp,Current Number: %Count% ;return ;RealTime: If Active = False return RealCount += 1 ;GuiControl,,CountSWp,Actual Elapsed Seconds: %RealCount% TTS(Count) return TTS(sSpeechText, dwFlags=0) { ;For info on the dwFlags bitmask see the SAPI helpfile: ;http://download.microsoft.com/download/speechSDK/SDK/5.1/WXP/EN-US/sapi.chm static TTSInitialized, ppSpVoice, pSpeak wSpeechTextBufLen:=VarSetCapacity(wSpeechText, StrLen(sSpeechText)*2+2,0) DllCall("MultiByteToWideChar", "UInt", 0, "UInt", 0, "Str", sSpeechText, "Int", -1, "UInt", &wSpeechText, "Int", wSpeechTextBufLen/2) if !TTSInitialized { ComInit := DllCall("ole32\CoInitialize", "Uint", 0) if ComInit not in 0,1 return "CoInitialize() failed: " ComInit sCLSID_SpVoice:="{96749377-3391-11D2-9EE3-00C04F797396}" sIID_ISpeechVoice:="{269316D8-57BD-11D2-9EEE-00C04F797396}" ;Make space for unicode representations. wCLSID_SpVoiceBufLen:=VarSetCapacity(wCLSID_SpVoice, StrLen(sCLSID_SpVoice)*2+2) wIID_ISpeechVoiceBufLen:=VarSetCapacity(wIID_ISpeechVoice, StrLen(sIID_ISpeechVoice)*2+2) ;Convert to unicode DllCall("MultiByteToWideChar", "UInt",0, "UInt",0, "Str",sCLSID_SpVoice, "Int",-1, "UInt",&wCLSID_SpVoice, "Int",wCLSID_SpVoiceBufLen/2) DllCall("MultiByteToWideChar", "UInt",0, "UInt",0, "Str",sIID_ISpeechVoice, "Int",-1, "UInt",&wIID_ISpeechVoice, "Int",wIID_ISpeechVoiceBufLen/2) ;Convert string representations to originals. VarSetCapacity(CLSID_SpVoice, 16) VarSetCapacity(IID_ISpeechVoice, 16) if ret:=DllCall("ole32\CLSIDFromString", "str", wCLSID_SpVoice, "str", CLSID_SpVoice) { DllCall("ole32\CoUninitialize") return "CLSIDFromString() failed: " ret } if ret:=DllCall("ole32\IIDFromString", "str", wIID_ISpeechVoice, "str", IID_ISpeechVoice) { DllCall("ole32\CoUninitialize") return "IIDFromString() failed: " ret } ;Obtain ISpeechVoice Interface. if ret:=DllCall("ole32\CoCreateInstance", "Uint", &CLSID_SpVoice, "Uint", 0, "Uint", 1, "Uint", &IID_ISpeechVoice, "UintP", ppSpVoice) { DllCall("ole32\CoUninitialize") return "CoCreateInstance() failed: " ret } ;Get pointer to interface. DllCall("ntdll\RtlMoveMemory", "UintP", pSpVoice, "Uint", ppSpVoice, "Uint", 4) ;Get pointer to Speak(). DllCall("ntdll\RtlMoveMemory", "UintP", pSpeak, "Uint", pSpVoice + 4*28, "Uint", 4) if ret:=DllCall(pSpeak, "Uint", ppSpVoice, "str" , wSpeechText, "Uint", dwFlags, "Uint", 0) { DllCall("ole32\CoUninitialize") return "ISpeechVoice::Speak() failed: " ret } DllCall("ole32\CoUninitialize") TTSInitialized = 1 return } if ret:=DllCall(pSpeak, "Uint", ppSpVoice, "str" , wSpeechText, "Uint", dwFlags, "Uint", 0) return "ISpeechVoice::Speak() failed: " ret } Features: - Press start to make it start counting. It will keep going forever just as long as the script doesn't close - The pause key is now fully functional - There is also a little counter at the bottom that displays the current number. - And one more thing - hotkeys. Alt+P to pause counting, Alt+S to stop counting Known Limitations: - If the script is counting a very large number (ex. one trillion, ten billion, one million, ten thousand, three hundred and fifty four.  ) the script will take a few seconds to pause/stop (it will first finish saying the current number) 
|
|
|
|
|