Jump to content

Help with useage of FOR


Recommended Posts

Hey,

I have problem with FOR. I would like to achieve something like this:

#cs
$line_01_entry_1 = GUICtrlCreateInput ("", -90,  10, 0, $nr_line)
$line_02_entry_1 = GUICtrlCreateInput ("", -90,  10, 0, $nr_line)
$line_03_entry_1 = GUICtrlCreateInput ("", -90,  10, 0, $nr_line)
#ce

So later on i could use $line_01_entry_1 with GUIRead. I tried diffrent combinations but all i could do was:

For $i = 00 to 09 Step +1
    $string = GUICtrlCreateInput ("", -90,  10, 0, $nr_line)
Next

But with this code i don't know how to get 'info' later on with GUIRead. Pls help :lmao:

My little company: Evotec (PL version: Evotec)

Link to post
Share on other sites
  • Developers

Dim $H_Input[10]
For $i = 0 to 9 
    $H_Input[$i] = GUICtrlCreateInput ("", -90,  10, 0, $nr_line)
Next

You can now read the controls with GUICtrlRead($H_Input[0]) ... etc..

p.s. This is the correct forum for GUI questions...

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

Link to post
Share on other sites

At least you didn't post in "Scripts and Scripts". I'd say you're close enough.

The best way is to use arrays.... Here's a recent post of mine that has a GUI example with arrays:

http://www.autoitscript.com/forum/index.php?showtopic=20468

Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Link to post
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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...