Skip to content

Instantly share code, notes, and snippets.

View kissgyorgy's full-sized avatar

György Kiss kissgyorgy

View GitHub Profile
@kissgyorgy
kissgyorgy / image-replacement.css
Last active April 14, 2018 13:12
CSS: Image Replacement
.ir {
border: 0;
font: 0/0 a;
text-shadow: none;
color: transparent;
background-color: #transparent;
}
@kissgyorgy
kissgyorgy / self_restart.au3
Last active December 10, 2015 00:19
AutoIt: self restart
; Author UP_NORTH
Func RestartScript()
If @Compiled = 1 Then
Run( FileGetShortName(@ScriptFullPath))
Else
Run( FileGetShortName(@AutoItExe) & " " & FileGetShortName(@ScriptFullPath))
EndIf
Exit
EndFunc
@kissgyorgy
kissgyorgy / delete_current_script.au3
Last active December 10, 2015 00:19
AutoIt: Delete current script
; IMPORTANT MAKE A COPY OF SCRIPT BEFORE DELETION
; Deletes the running script
; Author Larry
Func SuiCide()
$SC_File = @TEMPDIR & "\suicide.bat"
FileDelete($SC_File)
$SC_batch = 'loop:' & @CRLF & 'del "' & @SCRIPTFULLPATH & '"' & @CRLF & _
'ping -n 1 -w 250 zxywqxz_q' & @CRLF & 'if exist "' & @SCRIPTFULLPATH & _
'" goto loop' & @CRLF & 'del suicide.bat' & @CRLF
@kissgyorgy
kissgyorgy / gist:4433092
Created January 2, 2013 08:47
vBulletin 4.2 spoiler code
<div style="margin:10px; margin-top:5px">
<div style="margin-bottom:2px">
<b>Spoiler</b>: <input class="button" type="button" value="Mutat" onclick="rejt(this)">
</div>
<div style="margin: 0px; padding: 6px; border: 1px inset;">
<div class="spoiler" style="visibility: hidden;">
{param}
</div>
</div>
</div>
@kissgyorgy
kissgyorgy / click_tray_icon.au3
Last active December 21, 2020 17:29
Autoit: Click a Tray icon in Windows 7
#Include <GuiToolBar.au3>
$hSysTray = ControlGetHandle('[Class:Shell_TrayWnd]', '', '[Class:ToolbarWindow32;Instance:1]')
For $i = 1 To _GUICtrlToolbar_ButtonCount($hSystray)
$sCurrent = _GUICtrlToolbar_GetButtonText($hSystray,$i)
;~ ConsoleWrite($i & ": " & $sCurrent & @CRLF)
If $sCurrent = $sToolTip Then
_GUICtrlToolbar_ClickButton($hSystray, $i, "left")
ExitLoop
@kissgyorgy
kissgyorgy / enable_disable_buttons.au3
Last active July 1, 2021 00:57
AutoIt: Enable or Disable Window buttons via DllCall()
; Original script: http://www.autoitscript.com/forum/topic/100125-disable-close-button/#entry716490
; USer32.dll functions: http://msdn.microsoft.com/en-us/library/ms647985(v=vs.85).aspx
; "The first script ( remove the button ) work fine on XP, the second ( the disable script ) disable only the close button, i have tested both version, the dll and the GuiMenu"
; See http://www.autoitscript.com/forum/topic/147424-disable-or-remove-close-minimize-maximize-buttons-on-any-window-in-runtime/#entry1045390
; ---------------------------------------
#include <GuiMenu.au3>
Run("Notepad")
WinWait("Untitled - Notepad")
@kissgyorgy
kissgyorgy / set_style.au3
Created January 13, 2013 01:01
AutoIt: Set window style in runtime
; For explanation, see this forum topic: http://www.autoitscript.com/forum/topic/147424-disable-or-remove-close-minimize-maximize-buttons-on-any-window-in-runtime/
#include <WinAPI.au3>
#include <Constants.au3>
#include <WindowsConstants.au3>
$h = WinGetHandle("Untitled - Note")
$iOldStyle = _WinAPI_GetWindowLong($h, $GWL_STYLE)
ConsoleWrite("+ old style: " & $iOldStyle & @CR)
@kissgyorgy
kissgyorgy / edit_script.au3
Last active December 11, 2015 01:19
AutoIt: Edit script
Func EditScript()
ShellExecuteWait(@ProgramFilesDir & '\AutoIt3\SciTE\SciTE.exe', @ScriptFullPath, @ScriptDir)
RestartScript()
EndFunc
@kissgyorgy
kissgyorgy / locktaskbar.au3
Created January 14, 2013 17:04
AutoIt: Lock/Unlock Windows taskbar in Windows 7
#include <WinAPI.au3>
#include <WindowsConstants.au3>
$iPrevState = LockTaskBar(1)
Func LockTaskBar($iLock)
41If @OSVersion <> "WIN_7" Then
MsgBox(16,"Onyl on Windows 7", "The taskbar can only be locked this way in Windows 7 !")
Return
EndIf
@kissgyorgy
kissgyorgy / always_on_top.au3
Created January 15, 2013 04:22
AutoIt: Always on top window
Func SetAlwaysOnTop($hWnd)
_WinAPI_SetWindowPos($hWnd, $HWND_TOP+$HWND_TOPMOST, 0, 0, 0, 0, BitOr($SWP_NOMOVE, $SWP_NOSIZE))
EndFunc