AutoHotkey Community

It is currently May 27th, 2012, 11:55 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: October 12th, 2010, 6:25 am 
Offline

Joined: February 5th, 2009, 9:12 am
Posts: 59
been using 2 scripts for a long time now, had to make a windows fresh install, now, those 2 scripts are executing like 20 times each, even with
#singleinstance force


They've been working fine for me in the other install, why did this happened suddenly?

Image

Windows 7 Professional x64
4gb Ram


Code:
;#####################################################################################################################################
;########################################                        #####################################################################
;########################################   AREA AUTOEXECUTABLE  #####################################################################
;########################################                        #####################################################################
;#####################################################################################################################################
#include functions.ahk
#UseHook Off
;SetWorkingDir %A_ScriptDir%    ; Ensures a consistent starting directory.
#SingleInstance force       ; only one instance allowed, close old instances without warning
COM_Init()
;InitOSD()
PosX = 570 ;1000
PosY = 0 ;755     
RearMicMute_Display(PosX, PosY)
FrontMicMute_Display(PosX, PosY)
LineInMute_Display(PosX, PosY)
MasterMute_Display(PosX, PosY)
If (A_IsCompiled != 1)            ; automatically reload the script if not compiled
    SetTimer,Update_Script,1000
return



;#####################################################################################################################################
;########################################                        #####################################################################
;########################################   COMANDOS WINDOWPAD   #####################################################################
;########################################                        #####################################################################
;#####################################################################################################################################
#Numpad1::WindowPad_Move(-1, +1,  0.5, 0.5)
#Numpad2::WindowPad_Move(0, +1,  1.0, 0.5)
#Numpad3::WindowPad_Move(1, +1,  0.5, 0.5)
#Numpad4::WindowPad_Move(-1,  0,  0.5, 1.0)
#Numpad5::WindowPad_Move(0,  0,  0.5, 1.0)
#Numpad6::WindowPad_Move(+1,  0,  0.5, 1.0)
#Numpad7::WindowPad_Move(-1, -1,  0.5, 0.5)
#Numpad8::WindowPad_Move(0, -1,  1.0, 0.5)
#Numpad9::WindowPad_Move(+1, -1,  0.5, 0.5)
#!NumpadAdd::MaximizeToggle(P)
#!NumpadSub::Minimize()
^#!NumpadSub::UnMinimize()
#NumpadEnter::
#Enter::
WindowScreenMove(Next)
return
#NumpadDiv::GatherWindows(1)
#NumpadMult::GatherWindows(2)
^+c::Sendinput, {altdown}tu{altup}{tab}{space}


;#####################################################################################################################################
;########################################                                   ##########################################################
;########################################   LLAMADAS A FUNCIONES INTERNAS   ##########################################################
;########################################                                   ##########################################################
;#####################################################################################################################################
^#Numpad0::RearMicVolMute(PosX, PosY)
#Numpad0::FrontMicVolMute(PosX, PosY)
#!Numpad0::LineInVolMute(PosX, PosY)
Volume_Mute::
^#!NumPad0::
MasterVolMute(PosX, PosY)
return

;#####################################################################################################################################
;########################################                     ########################################################################
;########################################   AREA DE HOTKEYS   ########################################################################
;########################################                     ########################################################################
;#####################################################################################################################################
/*
^!Numpad1::Send, 1
^!Numpad2::Send, 2
^!Numpad3::Send, 3
^!Numpad4::Send, 4
^!Numpad5::Send, 5
^!Numpad6::Send, 6
^!Numpad7::Send, 7
^!Numpad8::Send, 8
^!Numpad9::Send, 9
^!Numpad0::Send, 0
*/
^Launch_Mail::Run C:\Program Files (x86)\Windows Live\Messenger\msnmsgr.exe
Browser_Search::Run, e:\mirc\mirc.exe
^Browser_Search::Run, C:\Program Files (x86)\FlashFXP\flashfxp.exe
^#Browser_Search::run, C:\Program Files (x86)\FileZilla FTP Client\filezilla.exe
Browser_Favorites::Run, D:\SHIP\Advanced file Organizer\aforg.exe
^Browser_Favorites::Run, C:\Program Files (x86)\010 Editor v3\010Editor.exe
Browser_Home::Run, %programfiles%\Mozilla Firefox\firefox.exe
^Browser_Home::Run, C:\Users\bidomo\AppData\Local\Google\Chrome\Application\chrome.exe
^#Browser_Home::Run, C:\Program Files (x86)\Internet Explorer\iexplore.exe
Browser_Stop::Run, %programfiles%\utorrent\utorrent.exe
^Browser_Stop::Run, D:\JDownloader 0.8\JDownloader.exe
^#F1::
^#Browser_Back::run, C:\Program Files (x86)\Winamp\winamp.exe
^#F2::
#!Browser_Forward::Send {media_play_pause} ;{Media_Play_Pause}
^#F3::
#Browser_Back::Send,{Media_Prev}
^#F4::
#Browser_Forward::Send,{Media_Next}
^#F5::
#Browser_Stop::send, {media_stop}

^#Browser_Stop::Run, C:\utorrent\utorrent.exe /RECOVER
#F12::Run, "E:\Lo del cesar\AutoHotkey104706\autohotkey.exe" "script de huevos.ahk", E:\Lo del cesar\AutoHotkey104706
#!a::Run, E:\Lo del cesar\AutoHotkey104706\lib\ASCII.ahk
#!r::Run, regedit.exe
#!p::Run, E:\lo del cesar\AutoHotkey104706\MyMultiScript
#!d::Run, diskmgmt.msc
Launch_App1::Send, #e
#ScrollLock::Run, devmgmt.msc
#xbutton1::sendinput, {f2}^v{enter}
#xbutton2::sendinput, {f2}^c{esc}       
^#left::sendinput, {f2}{home}{del 8}{enter}{home}
^insert::sendinput, {down 4}{end}{;}




;^end::VA_SetMute(!VA_GetMute(2),2)
/*
^#End::
    SetKeyDelay, 0, 50
    ControlSend, VideoRenderer1, {space}, ahk_class MediaPlayerClassicW
return
*/

^#Up::
IfWinExist, ahk_class eHome Render Window
{
Process, Exist, SndVol.exe
SndVolPID = %ErrorLevel%
If SndVolPID = 0
   {
      Run, SndVol.exe, , , SndVolPID
      Sleep, 120
   }
;ControlSend, ToolbarWindow326, {Space}, SndVol.exe ; Toggles the mute control for Media Center
ControlFocus, msctls_trackbar322, ahk_pid %SndVolPID%
ControlSend, msctls_trackbar322,{up}, ahk_pid %SndVolPID%
;MsgBox, %ErrorLevel%
return
}
VA_SetMasterMute(false)
Gui, 4:destroy
Vol_Display(device:="Master Volume",id:=1,vol:=1,color:="Green")
SetTimer,vol_BarOff,2500
return

^#Down::
ifWinExist, ahk_class eHome Render Window
{
Process, Exist, SndVol.exe
SndVolPID = %ErrorLevel%
If SndVolPID = 0
   {
      Run, SndVol.exe, , , SndVolPID
      Sleep, 120
   }
;ControlSend, ToolbarWindow326, {Space}, SndVol.exe ; Toggles the mute control for Media Center
ControlFocus, msctls_trackbar322, ahk_pid %SndVolPID%
ControlSend, msctls_trackbar322, {down}, ahk_pid %SndVolPID%
;MsgBox, %ErrorLevel%
return
}
Vol_Display(device:="Master Volume",id:=1,vol:=-1,color:="Green")
SetTimer,vol_BarOff,2500
return

^#!Up::
volume_Up::
VA_SetMasterMute(false)
Gui, 4:destroy
Vol_Display(device:="Master Volume",id:=1,vol:=5,color:="Green")
SetTimer,vol_BarOff,2500
return

^#!Down::
volume_Down::
Vol_Display(device:="Master Volume",id:=1,vol:=-5,color:="Green")
SetTimer,vol_BarOff,2500
return

+^Up::
VA_SetMute(false, 7)
Gui, destroy
Vol_Display(device:="Rear Mic",id:=7,vol:=1,color:="Maroon")
SetTimer,vol_BarOff,2500
return

+^Down::
Vol_Display(device:="Rear Mic",id:=7,vol:=-1,color:="Maroon")
SetTimer,vol_BarOff,2500
return

+#Up::
VA_SetMute(false, 8)
Gui, 2:destroy
Vol_Display(device:="Front Mic",id:=8,vol:=1,color:="Red")
SetTimer,vol_BarOff,2500
return

+#Down::
Vol_Display(device:="Front Mic",id:=8,vol:=-1,color:="Red")
SetTimer,vol_BarOff,2500
return

+!Up::
VA_SetMute(false, 9)
Gui, 3:destroy
Vol_Display(device:="Line in",id:=9,vol:=1,color:="Blue")
SetTimer,vol_BarOff,2500
return

+!Down::
Vol_Display(device:="Line in",id:=9,vol:=-1,color:="Blue")
SetTimer,vol_BarOff,2500
return



;#####################################################################################################################################
;########################################                        #####################################################################
;########################################   AREA DE HOTSTRINGS   #####################################################################
;########################################                        #####################################################################
;#####################################################################################################################################
:://spidey::
ASCII_spidey()
return

:://kon::
ASCII_kon()
return

:://perritas::
ASCII_perritas()
return

:://babe::
ASCII_beba()
return

;#####################################################################################################################################
;########################################                     ########################################################################
;########################################   AREA DE SHIIIIT   ########################################################################
;########################################                     ########################################################################
;#####################################################################################################################################
#n::
if WinActive("ahk_class CabinetWClass") or WinActive("ahk_class Progman")
   {
      sendinput, {appskey}w{enter}
   }
Return

^!s::
i=1
while i<=250
    {
        sendinput, %i% {space 10} {asc %i%}{enter}
        i++
    }
return


#IfWinExist, ahk_class eHome Render Window
;sc120:: ; scancode for the Mute key
Process, Exist, SndVol.exe
SndVolPID = %ErrorLevel%
If SndVolPID = 0
   {
      Run, SndVol.exe, , , SndVolPID
      Sleep, 120
   }
;ControlSend, ToolbarWindow326, {Space}, SndVol.exe ; Toggles the mute control for Media Center
;ControlFocus, Mute for Windows Media Center, ahk_pid %SndVolPID%
;ControlSend, Mute for Windows Media Center, {Space}, ahk_pid %SndVolPID%
;MsgBox, %ErrorLevel%
return




;#####################################################################################################################################
;########################################                                #############################################################
;########################################   AREA DE FUNCIONES INTERNAS   #############################################################
;########################################                                #############################################################
;#####################################################################################################################################
;-------------------------------------------------------------------------
;    Auto reload script for development
;-------------------------------------------------------------------------







Update_Script:
    Loop, %A_ScriptDir%\*.ahk                ; loop all AHK-scripts in current folder (includes as well)
    {
        FileGetAttrib,attribs,%A_LoopFileFullPath%    ; get file attribute
        IfInString,attribs,A                ; if archive attribute is set, the script was changed
        {
            FileSetAttrib,-A,%A_LoopFileFullPath%    ; remove archive attribute
            Reload                    ; reload the script
        }
    }
Return

vol_BarOff:
   Gui, 5:Destroy
return



The other script is the remote script for AHKHID by TheGood http://www.autohotkey.com/forum/viewtopic.php?t=41397&postdays=0&postorder=asc&start=165


Last edited by bidomo on October 16th, 2010, 8:56 am, edited 1 time in total.

Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 12th, 2010, 4:31 pm 
Offline

Joined: February 29th, 2008, 8:36 pm
Posts: 901
Location: Vault 7
Just a quick check, what happens if you move your mouse over all those icons? Sometimes the icons just don't refresh.

_________________
ImageDebugging,Container,FileContainer,Object Preferences,ShellFileOperation


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 15th, 2010, 4:40 am 
Offline

Joined: February 5th, 2009, 9:12 am
Posts: 59
Rapte_Of_Suzaku wrote:
Just a quick check, what happens if you move your mouse over all those icons? Sometimes the icons just don't refresh.


No, it says it could replace the last instance and multiplies again, thousands of copies in process list.

I think it had something to do with MCE and the script autoloading feature.

is not happening anymore, but that was really strange...


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: BrandonHotkey, Google Feedfetcher and 18 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group