Jump to content

Select element in Start Menu


 Share

Recommended Posts

Not sure why you want to open an item from the start menu, maybe I am missing something.

What is this "DESLG98" you are trying to open ?

<{POST_SNAPBACK}>

It is an archive PIF that restarts the Windows in MSDOS mode and executes a program that only informs that the computer can be off. Use today this resource for computers with Windows 98 that present problems to turn off.
Link to comment
Share on other sites

Try

$PifPath = 'EnterPathHere'
Run(@ComSpec & ' /c "' & $PifPath  & '"','',@SW_HIDE)

<{POST_SNAPBACK}>

Already I tried this method, but it does not function. The AUTOIT does not restart the Windows, only execute the file PIF in second plain. However, if I make one click on the archive pif, it I restart as I desire.
Link to comment
Share on other sites

Already I tried this method, but it does not function. The AUTOIT does not restart the Windows, only execute the file PIF in second plain. However, if I make one click on the archive pif, it I restart as I desire.

<{POST_SNAPBACK}>

Thats odd, it should work, if you must click it then open the start menu via Send keys then use ControlListView to select the proper "PIF" then use {ENTER] from Send to open.

Strapped for time right now got to go, good luck.

Edited by bshoenhair
Link to comment
Share on other sites

Thats odd, it should work, if you must click it then open the start menu via Send keys then use ControlListView to select the proper "PIF" then use {ENTER] from Send to open.

Strapped for time right now got to go, good luck.

<{POST_SNAPBACK}>

I do not know to use the ControlListView function. You have an example I to examine?
Link to comment
Share on other sites

How I open way AUTOIT a folder "C:\Tmp" and execute a specific archive inside of it, using controlclick?

<{POST_SNAPBACK}>

Not ControlClick, look at the following Example.

This example will create a test.txt file in the Temp dir, then open the temp dir, select the test.txt file and open it.

Opt("WinTitleMatchMode",2)
FileWrite(@TempDir & '\test.txt','Hello, this is a test file')
$WinTitle = 'Temp' 
$WinText = ''
$FileName = 'test.txt'
Run('explorer ' & @TempDir)
WinWait($WinTitle)
$NameIndex = ControlListView($WinTitle,$WinText,'SysListView321',"FindItem",$FileName)
If $NameIndex <> -1 Then
    ControlListView($WinTitle,$WinText,'SysListView321',"Select",$NameIndex)
    ControlSend($WinTitle,$WinText,'SysListView321','{ENTER}')
Else
    MsgBox(0,'Not Found',$FileName & ' was not found.')
EndIf
Link to comment
Share on other sites

Not ControlClick, look at the following Example.

This example will create a test.txt file in the Temp dir, then open the temp dir, select the test.txt file and open it.

Opt("WinTitleMatchMode",2)
FileWrite(@TempDir & '\test.txt','Hello, this is a test file')
$WinTitle = 'Temp' 
$WinText = ''
$FileName = 'test.txt'
Run('explorer ' & @TempDir)
WinWait($WinTitle)
$NameIndex = ControlListView($WinTitle,$WinText,'SysListView321',"FindItem",$FileName)
If $NameIndex <> -1 Then
    ControlListView($WinTitle,$WinText,'SysListView321',"Select",$NameIndex)
    ControlSend($WinTitle,$WinText,'SysListView321','{ENTER}')
Else
    MsgBox(0,'Not Found',$FileName & ' was not found.')
EndIf

<{POST_SNAPBACK}>

Thanks, my friend. With its last example, more detailed, I obtained to finish the program that was making. He forgives me for my precarious English.
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...