Jump to content

Recommended Posts

Posted

While $msg <> $GUI_EVENT_CLOSE
$msg = GUIGetMsg()
         Select
             
             Case $msg = $r1
         $num = IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Amn", "NotFound")
         moverune()

         EndSelect
WEnd


Exit

Func moverune()

no matter what i press (minimize,maximize,close or any checkbox) it will go to the function "moverune()"

i have 33 checkboxes $r1 through $r33 and i have not included the gui, i did not think it was relevant.

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

  • Replies 69
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • Moderators
Posted

Anytime your asking for help debugging, it's relevant. A pseudo-code doesn't always show the flaw.

What is $r1 ? Just the Checkbox variable?

Case GUICtrlRead($r1) = 1
            $num = IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Amn", "NotFound")
            moverune()

If your using alot of CheckBoxes... maybe Opt('GUIOnEventMode', 1) is a better option for you.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted (edited)

i think the guigetmsg needs to be before the while

nope. lol

here is more of the code.

#include <GuiConstants.au3>
$msg = 0
GUICreate("Controls", 217,@DesktopHeight,0,0)

GUICtrlCreateGroup("Runes / Amounts", 2, 0, 213, 235)
$r1 = GUICtrlCreateRadio("Amn  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Amn", "NotFound"), 4, 13, 68)
$r2 = GUICtrlCreateRadio("Ber  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ber", "NotFound"), 74, 13, 68)
$r3 = GUICtrlCreateRadio("Cham  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Cham", "NotFound"), 144, 13, 68)

$r4 = GUICtrlCreateRadio("Dol  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Dol", "NotFound"), 4, 33, 70)
$r5 = GUICtrlCreateRadio("El  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "El", "NotFound"), 74, 33, 70)
$r6 = GUICtrlCreateRadio("Eld  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Eld", "NotFound"), 144, 33, 70)

$r7 = GUICtrlCreateRadio("Eth  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Eth", "NotFound"), 4, 53, 70)
$r8 = GUICtrlCreateRadio("Fal  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Fal", "NotFound"), 74, 53, 70)
$r9 = GUICtrlCreateRadio("Gul  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Gul", "NotFound"), 144, 53, 70)

$r10 = GUICtrlCreateRadio("Hel  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Hel", "NotFound"), 4, 73, 70)
$r11 = GUICtrlCreateRadio("Io  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Io", "NotFound"), 74, 73, 70)
$r12 = GUICtrlCreateRadio("Ist  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ist", "NotFound"), 144, 73, 70)

$r13 = GUICtrlCreateRadio("Ith  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ith", "NotFound"), 4, 93, 70)
$r14 = GUICtrlCreateRadio("Jah  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Jah", "NotFound"), 74, 93, 70)
$r15 = GUICtrlCreateRadio("Ko  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ko", "NotFound"), 144, 93, 70)

$r16 = GUICtrlCreateRadio("Lem  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Lem", "NotFound"), 4, 113, 70)
$r17 = GUICtrlCreateRadio("Lo  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Lo", "NotFound"), 74, 113, 70)
$r18 = GUICtrlCreateRadio("Lum  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Lum", "NotFound"), 144,113, 70)

$r19 = GUICtrlCreateRadio("Mal  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Mal", "NotFound"), 4, 133, 70)
$r20 = GUICtrlCreateRadio("Nef  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Nef", "NotFound"), 74, 133, 70)
$r21 = GUICtrlCreateRadio("Ohm  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ohm", "NotFound"), 144, 133, 70)

$r22 = GUICtrlCreateRadio("Ort  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ort", "NotFound"), 4, 153, 70)
$r23 = GUICtrlCreateRadio("Pul  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Pul", "NotFound"), 74, 153, 70)
$r24 = GUICtrlCreateRadio("Ral  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Ral", "NotFound"), 144, 153, 70)

$r25 = GUICtrlCreateRadio("Shael  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Shael", "NotFound"), 4, 173, 70)
$r26 = GUICtrlCreateRadio("Sol  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Sol", "NotFound"), 74, 173, 70)
$r27 = GUICtrlCreateRadio("Sur  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Sur", "NotFound"), 144, 173, 70)

$r28 = GUICtrlCreateRadio("Tal  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Tal", "NotFound"), 4, 193, 70)
$r29 = GUICtrlCreateRadio("Tir  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Tir", "NotFound"), 74, 193, 70)
$r30 = GUICtrlCreateRadio("Thul  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Thul", "NotFound"), 144, 193, 70)

$r31 = GUICtrlCreateRadio("Um  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Um", "NotFound"), 4, 213, 70)
$r32 = GUICtrlCreateRadio("Vex  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Vex", "NotFound"),74, 213, 70)
$r33 = GUICtrlCreateRadio("Zod  " & IniRead(@ScriptDir & "/Settings.ini", "RuneAmounts", "Zod", "NotFound"), 144, 213, 53)
GUICtrlCreateGroup("", -99, -99, 1, 1);close group

GUISetState()

SplashTextOn("Assistant","Ready to Go!",@DesktopWidth - 227,100,221,0)
WinActivate("Diablo II")
winmove("Diablo II","",221,104,806,636 )
While $msg <> $GUI_EVENT_CLOSE
$msg = GUIGetMsg()
         Select
             
             Case $msg = $r1
         moverune()

         EndSelect
WEnd


Exit

Func moverune()
msgbox(0,"test","why the hell am i executing?")
endfunc
Edited by t0ddie

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Posted

if you run this it malfunctions the first time you click something.

then it seems to work fine if you leave it running.

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

  • Moderators
Posted (edited)

I gave you the answer t0ddie.

Edit:

Let me clarify:

GUICtrlRead($r1) = 1 ; This is checking to see if it is checked.

GUICtrlRead($r1) = 4 ; This is checking to see if it is unchecked.

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted

i have another script with the same thing... but doesnt use that

Opt('GUIOnEventMode', 1)

and it works fine

also, this works fine after the first time.

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

  • Developers
Posted (edited)

heres a stripped down version to shows the issue:

#include <GuiConstants.au3>
$msg = 0
GUICreate("Controls", 217, @DesktopHeight, 500, 0)
GUICtrlCreateGroup("Runes / Amounts", 2, 0, 213, 235)
$r1 = GUICtrlCreateRadio("Amn  ", 4, 13, 68)
$r2 = GUICtrlCreateRadio("Ber  ", 74, 13, 68)
GUICtrlCreateGroup("", -99, -99, 1, 1);close group
GUISetState()
ConsoleWrite('@@ Debug(60) : $r1 = ' & $r1 & @lf & '>Error code: ' & @error & @lf);### Debug Console
While $msg <> $GUI_EVENT_CLOSE
    $msg = GUIGetMsg()
    if $msg < 1 then ContinueLoop
    ConsoleWrite('@@ Debug(57) : $msg = ' & $msg & @lf & '>Error code: ' & @error & @lf);### Debug Console
WEnd

It shows that the first GUIGetMsg() returns a 4 which is the $R1.

Don't know why it does this yet....

EDIT: Easy fix for this moment is to add "$msg = GUIGetMsg()" before the While ....

Edited by JdeB

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

Posted

i have another script with the same thing... but doesnt use that

Opt('GUIOnEventMode', 1)

and it works fine

also, this works fine after the first time.

why are you setting $msg=0 at the top of your code?
Posted (edited)

this happen because $r1 is the first radio-Control on your Gui and is selected by default on loading

Edited by jonk
Posted (edited)

heres another that works fine

#include <GuiConstants.au3>
GUICreate("Assistant", 400, 450)
GUICtrlCreateGroup("Runes / Amounts", 20, 230, 360, 180)


$r1 = GUICtrlCreateRadio("Amn  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Amn", "NotFound"), 25, 245, 70)
$r2 = GUICtrlCreateRadio("Ber  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ber", "NotFound"), 25, 265, 70)
$r3 = GUICtrlCreateRadio("Cham  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Cham", "NotFound"), 25, 285, 70)
$r4 = GUICtrlCreateRadio("Dol  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Dol", "NotFound"), 25, 305, 70)
$r5 = GUICtrlCreateRadio("El  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "El", "NotFound"), 25, 325, 70)
$r6 = GUICtrlCreateRadio("Eld  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Eld", "NotFound"), 25, 345, 70)
$r7 = GUICtrlCreateRadio("Eth  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Eth", "NotFound"), 25, 365, 70)
$r8 = GUICtrlCreateRadio("Fal  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Fal", "NotFound"), 25, 385, 70)


$r9 = GUICtrlCreateRadio("Gul  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Gul", "NotFound"), 100, 245, 70)
$r10 = GUICtrlCreateRadio("Hel  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Hel", "NotFound"), 100, 265, 70)
$r11 = GUICtrlCreateRadio("Io  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Io", "NotFound"), 100, 285, 70)
$r12 = GUICtrlCreateRadio("Ist  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ist", "NotFound"), 100, 305, 70)
$r13 = GUICtrlCreateRadio("Ith  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ith", "NotFound"), 100, 325, 70)
$r14 = GUICtrlCreateRadio("Jah  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Jah", "NotFound"), 100, 345, 70)
$r15 = GUICtrlCreateRadio("Ko  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ko", "NotFound"), 100, 365, 70)
$r16 = GUICtrlCreateRadio("Lem  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Lem", "NotFound"), 100, 385, 70)


$r17 = GUICtrlCreateRadio("Lo  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Lo", "NotFound"), 175, 245, 70)
$r18 = GUICtrlCreateRadio("Lum  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Lum", "NotFound"), 175, 265, 70)
$r19 = GUICtrlCreateRadio("Mal  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Mal", "NotFound"), 175, 285, 70)
$r20 = GUICtrlCreateRadio("Nef  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Nef", "NotFound"), 175, 305, 70)
$r21 = GUICtrlCreateRadio("Ohm  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ohm", "NotFound"), 175, 325, 70)
$r22 = GUICtrlCreateRadio("Ort  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ort", "NotFound"), 175, 345, 70)
$r23 = GUICtrlCreateRadio("Pul  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Pul", "NotFound"), 175, 365, 70)
$r24 = GUICtrlCreateRadio("Ral  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ral", "NotFound"), 175, 385, 70)


$r25 = GUICtrlCreateRadio("Shael  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Shael", "NotFound"), 250, 245, 70)
$r26 = GUICtrlCreateRadio("Sol  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Sol", "NotFound"), 250, 265, 70)
$r27 = GUICtrlCreateRadio("Sur  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Sur", "NotFound"), 250, 285, 70)
$r28 = GUICtrlCreateRadio("Tal  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Tal", "NotFound"), 250, 305, 70)
$r29 = GUICtrlCreateRadio("Tir  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Tir", "NotFound"), 250, 325, 70)
$r30 = GUICtrlCreateRadio("Thul  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Thul", "NotFound"), 250, 345, 70)
$r31 = GUICtrlCreateRadio("Um  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Um", "NotFound"), 250, 365, 70)
$r32 = GUICtrlCreateRadio("Vex  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Vex", "NotFound"), 250, 385, 70)


$r33 = GUICtrlCreateRadio("Zod  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Zod", "NotFound"), 325, 245, 53)



GUICtrlCreateGroup("", -99, -99, 1, 1);close group

GUISetState()
While 1
   $msg = GUIGetMsg()
   Select
      Case $msg = $GUI_EVENT_CLOSE
         Exit
         

         
     Case $msg = $r1
msgbox(0,"test","1")
    Case $msg = $r2
msgbox(0,"test","2")
     Case $msg = $r3
         msgbox(0,"test","3")
     EndSelect
 WEnd

it doesnt use opt and it works just fine

why are you setting $msg=0 at the top of your code?

i had to play with the code when i got the errors. and i got the error that $msg wasnt declared so i added it. there ya go Edited by t0ddie

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Posted

heres another that works fine

#include <GuiConstants.au3>
GUICreate("Assistant", 400, 450)
GUICtrlCreateGroup("Runes / Amounts", 20, 230, 360, 180)
$r1 = GUICtrlCreateRadio("Amn  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Amn", "NotFound"), 25, 245, 70)
$r2 = GUICtrlCreateRadio("Ber  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ber", "NotFound"), 25, 265, 70)
$r3 = GUICtrlCreateRadio("Cham  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Cham", "NotFound"), 25, 285, 70)
$r4 = GUICtrlCreateRadio("Dol  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Dol", "NotFound"), 25, 305, 70)
$r5 = GUICtrlCreateRadio("El  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "El", "NotFound"), 25, 325, 70)
$r6 = GUICtrlCreateRadio("Eld  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Eld", "NotFound"), 25, 345, 70)
$r7 = GUICtrlCreateRadio("Eth  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Eth", "NotFound"), 25, 365, 70)
$r8 = GUICtrlCreateRadio("Fal  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Fal", "NotFound"), 25, 385, 70)
$r9 = GUICtrlCreateRadio("Gul  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Gul", "NotFound"), 100, 245, 70)
$r10 = GUICtrlCreateRadio("Hel  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Hel", "NotFound"), 100, 265, 70)
$r11 = GUICtrlCreateRadio("Io  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Io", "NotFound"), 100, 285, 70)
$r12 = GUICtrlCreateRadio("Ist  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ist", "NotFound"), 100, 305, 70)
$r13 = GUICtrlCreateRadio("Ith  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ith", "NotFound"), 100, 325, 70)
$r14 = GUICtrlCreateRadio("Jah  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Jah", "NotFound"), 100, 345, 70)
$r15 = GUICtrlCreateRadio("Ko  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ko", "NotFound"), 100, 365, 70)
$r16 = GUICtrlCreateRadio("Lem  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Lem", "NotFound"), 100, 385, 70)
$r17 = GUICtrlCreateRadio("Lo  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Lo", "NotFound"), 175, 245, 70)
$r18 = GUICtrlCreateRadio("Lum  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Lum", "NotFound"), 175, 265, 70)
$r19 = GUICtrlCreateRadio("Mal  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Mal", "NotFound"), 175, 285, 70)
$r20 = GUICtrlCreateRadio("Nef  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Nef", "NotFound"), 175, 305, 70)
$r21 = GUICtrlCreateRadio("Ohm  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ohm", "NotFound"), 175, 325, 70)
$r22 = GUICtrlCreateRadio("Ort  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ort", "NotFound"), 175, 345, 70)
$r23 = GUICtrlCreateRadio("Pul  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Pul", "NotFound"), 175, 365, 70)
$r24 = GUICtrlCreateRadio("Ral  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Ral", "NotFound"), 175, 385, 70)
$r25 = GUICtrlCreateRadio("Shael  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Shael", "NotFound"), 250, 245, 70)
$r26 = GUICtrlCreateRadio("Sol  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Sol", "NotFound"), 250, 265, 70)
$r27 = GUICtrlCreateRadio("Sur  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Sur", "NotFound"), 250, 285, 70)
$r28 = GUICtrlCreateRadio("Tal  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Tal", "NotFound"), 250, 305, 70)
$r29 = GUICtrlCreateRadio("Tir  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Tir", "NotFound"), 250, 325, 70)
$r30 = GUICtrlCreateRadio("Thul  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Thul", "NotFound"), 250, 345, 70)
$r31 = GUICtrlCreateRadio("Um  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Um", "NotFound"), 250, 365, 70)
$r32 = GUICtrlCreateRadio("Vex  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Vex", "NotFound"), 250, 385, 70)
$r33 = GUICtrlCreateRadio("Zod  " & IniRead(@ScriptDir & "/Scam.ini", "RuneAmounts", "Zod", "NotFound"), 325, 245, 53)
GUICtrlCreateGroup("", -99, -99, 1, 1);close group

GUISetState()
While 1
   $msg = GUIGetMsg()
   Select
      Case $msg = $GUI_EVENT_CLOSE
         Exit
         

         
     Case $msg = $r1
msgbox(0,"test","1")
    Case $msg = $r2
msgbox(0,"test","2")
     Case $msg = $r3
         msgbox(0,"test","3")
     EndSelect
 WEnd

it doesnt use opt and it works just fine

you may have missed my last reply... take out the $msg=0 at the top.
  • Moderators
Posted (edited)

Well at the chance of sounding nieve... $msg = $r1 << what is that supposed to do? I mean is it supposed to say ok, you clicked this button, so let me do this... or ok it has this value so let me do this? What problems are you having, is the radio unchecked and it's doing something, or is it checked? Are you trying to show a bug, or find a solution?

Solution (Tested):

Case GUICtrlRead($r1) = 1; checked or you can use $GUI_CHECKED
moverune(); do your function
GUICtrlSetState($r1, 4); or you can use $GUI_UNCHECKED then uncheck so you don't keep doing the same thing

Edit:

This reminds of something the other day, where Jdeb was getting one set of results for someones code, and I was getting another. I can't duplicate an error, so the above may be null and void. (Must have the Jedi Version of AutoIt :P)

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted

smoke run my second code i posted that works just fine.

that is what i want to do.

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

  • Developers
Posted (edited)

heres another that works fine

it doesnt use opt and it works just fine

This script has the exact same problem !

This behaviour is only shown when BETA is used and doesn't show up when 3.1.1 is used.

It also only shows up when the first Control is a radio button..

Conclusion: Sounds like a BUG to me....

Edited by JdeB

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

Posted (edited)

i am running both scripts uncompiled

one works, one doesnt

my version is... 3.1.1.0

so i dont understand what you mean

Edited by t0ddie

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Posted

This script has the exact same problem !

This behaviour is only shown when BETA is used and doesn't show up when 3.1.1 is used.

It also only shows up when the first Control is a radio button..

Conclusion: Sounds like a BUG to me....

if you change the

$msg = 0

at the top of the code to:

$msg = GUIGetMsg()

it works fine...

  • Moderators
Posted

if you change the

$msg = 0

at the top of the code to:

$msg = GUIGetMsg()

it works fine...

:P - Ooops, my turn Cam!!

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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
  • Recently Browsing   0 members

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