Jump to content

Problem With Au3gui And Gui.action


Guest kotschi
 Share

Recommended Posts

Guest kotschi

Does somebody know about the problem with the AU3GUI-Tool and the "GUI.action"="4"?

Here is my sample-code:

EnvSet("GUI.title","Radiobuttons")
EnvSet("GUI.focus","1")
EnvSet("GUI.action","4")
EnvSet("GUI.w","200")
EnvSet("GUI.h","100")

EnvSet("OBJ1.type","radio")
EnvSet("OBJ1.text","Button1")
EnvSet("OBJ1.x","10")
EnvSet("OBJ1.y","20")
EnvSet("OBJ1.w","100")
EnvSet("OBJ1.h","15")
EnvSet("OBJ1.selected","1")

EnvSet("OBJ2.type","radio")
EnvSet("OBJ2.text","Button2")
EnvSet("OBJ2.x","10")
EnvSet("OBJ2.y","40")
EnvSet("OBJ2.w","100")
EnvSet("OBJ2.h","15")

EnvSet("OBJ3.type","button")
EnvSet("OBJ3.text","&Next")
EnvSet("OBJ3.x","100")
EnvSet("OBJ3.y","60")
EnvSet("OBJ3.submit","1")
EnvSet("OBJ3.close","1")

RunWait("au3gui")
...

The problem is, that the tool doesn't set the data to the environment ("OBJ1","OBJ2",etc.)

Or can somebody explain me how the parameter '4' for the GUI.action works?

Thanks and regards

Link to comment
Share on other sites

  • Developers

Dunno why the env doesn't work... guess its lost after the au3gui ends.

To parse the info to your script you could use the below example...

EnvSet("GUI.title","Radiobuttons")
EnvSet("GUI.focus","1")
EnvSet("GUI.action","8")
EnvSet("GUI.w","200")
EnvSet("GUI.h","100")

EnvSet("OBJ1.type","radio")
EnvSet("OBJ1.text","Button1")
EnvSet("OBJ1.x","10")
EnvSet("OBJ1.y","20")
EnvSet("OBJ1.w","100")
EnvSet("OBJ1.h","15")
EnvSet("OBJ1.selected","1")

EnvSet("OBJ2.type","radio")
EnvSet("OBJ2.text","Button2")
EnvSet("OBJ2.x","10")
EnvSet("OBJ2.y","40")
EnvSet("OBJ2.w","100")
EnvSet("OBJ2.h","15")

EnvSet("OBJ3.type","button")
EnvSet("OBJ3.text","&Next")
EnvSet("OBJ3.x","100")
EnvSet("OBJ3.y","60")
EnvSet("OBJ3.submit","1")
EnvSet("OBJ3.close","1")

AutoItWinSetTitle("AU3GUI...")
RunWait("AU3GUI.exe")

$MyArray = ParseAU3GUI()
For $n = 1 to $MyArray[0]
   MsgBox(4096,$N,$MyArray[$n])
Next

; is from one of Larry's posts
Func ParseAU3GUI()
   $szBuffer = AutoItWinGetTitle()
   MsgBox(4096,"",$szBuffer)
   $aTemp = StringSplit($szBuffer,@LF & "=")
   $szBuffer = ""
   For $n = 3 to (UBound($aTemp)-1) Step 2
      $szBuffer = $szBuffer & $aTemp[$n] & @LF
   Next
   Return StringSplit(StringTrimRight($szBuffer,1),@LF)
EndFunc

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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...