Jump to content

Reveals Secret Progz commands


Amen
 Share

Recommended Posts

in Right you will see command names "Secret command shortcuts"

If you click Start->Run and type this command a prog will start..

$Prog_title="Secret App paths"
$RegProgzKey="HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths"
; Script by FeY  Amen
#include <GuiConstants.au3>
Opt("RunErrorsFatal",0)
DIM $Gui_pl=@DesktopWidth-(@DesktopWidth/3),$Gui_mh=330
GuiCreate($Prog_title,$Gui_pl, $Gui_mh,-1, -1 , $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS)
$listView = GUICtrlCreateListView("Secret Shortcut Name|Path Location|Prog Status", 10, 10, $Gui_pl-20, $Gui_mh-40,$LVS_REPORT)
$button_1=GUICtrlCreateButton("Run Selected",10,$Gui_mh-25,100,20)
$button_2=GUICtrlCreateButton("Find Target",110,$Gui_mh-25,100,20)
dim $listView_item[1]
        For $i=1 to 9999
            $msg=RegEnumKey($RegProgzKey,$i)
            If $msg="" then ExitLoop
            $msg2=RegRead($REgProgzKey&"\"&$msg,"")
        
            If StringInStr($msg2,"""")<>0 or StringInStr($msg2,"%")<>0 then 
                    $msg3="??";Cannot determine
            Else
                If FileExists($msg2) then 
                    $msg3="Available" 
                else 
                    $msg3="Not Availble!"
                Endif
            EndIF
            Redim $listView_item[$i+1]
            $listView_item[$i]=GuiCtrlCreateListViewItem($msg&"|"&$msg2&"|"&$msg3, $listView)
        Next        
        $MAXitems=$i
    ;GuiCtrlCreateListViewItem("B|Two|ghg", $listView)
    ;GuiCtrlCreateListViewItem("C|Three|gh", $listView)

GuiSetState()
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = -11 or $msg = 0 or $msg = -4 or $msg = -5
    case $msg=$button_2
          $msg=TakeSeletionMsg()
          If $msg<>"" then  
              
              Runwait(@ComSpec&" /c Explorer "&ExpPath ($msg[2]));,@SW_HIDE)
          Endif 
      case $msg=$button_1
          $msg=TakeSeletionMsg()
        If $msg<>"" then  Runwait(@ComSpec&" /c Start "&$msg[1]);,@SW_HIDE)
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case Else
    ;MsgBox(0,"",$msg)
    EndSelect
WEnd
Exit
Func TakeSeletionMsg()
         $msg=GUICtrlRead($listView)
         $msg=$msg-5
         If $msg>0 and $msg<=$MAXitems then 
            $msg=GUICtrlRead($listView_item[$msg])
            $msg=StringSplit($msg,"|")
            Return $msg
         EndIF
          Return ""
EndFunc
 Func  ExpPath ($msg);Returns the Path of an FullPath-Address Created by Amen!
      Return StringMid ($msg,1,StringInStr ($msg, "\" ,0,-1 ))
EndFunc

Put this to the start of your prog.After running once you can start your Prog

from "run" or from a dos windows just typing your prog name

;-----------------------------------------------------------------------------make  my prog  run from a run command
$SystemKeyname="HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\"&@ScriptName
RegWrite($SystemKeyname,"","REG_SZ",@ScriptFullPath)
RegWrite($SystemKeyname,"Path","REG_SZ",@ScriptDir)

To work Properly Dont forget to put also in your prog:

FileChangeDir (@ScriptDir);Added to Work like an internal dos command if setted to system path!(%path%)
Edited by Amen
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...