![]() |
|
|||||||
| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
| Questions & Help Needed Post any question regarding Basic4ppc. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
Would you see the following script sample :
i put 2 cascaded loops and the second one must modify the limit of the first. So : '---------------------------------------- Sub Globals 'listbox1 declared. 'tn = 0 'tm = 0 End Sub '-------------------------------------- Sub App_Start Form1.Show test End Sub '------------------------------------ Sub test tn=50 tm=5 n=0 For n = 0 To tn For m = 0 To tm If tm<7 Then : tm = tm+1 : End If If tn<100 Then : tn = tn+1 : End If Next listbox1.Add("n=" & n & " tn=" & tn & " tm=" & tm) Next listbox1.Add("fin ---- n=" & n & " tn=" & tn & " tm=" & tm) End Sub '---------------------------------- Result, (with tn and tm global or not) : tm is modified, BUT, tn is not ! (a '51' stop is curious !) Is it a kind of ADA-like safety limit ? Sure, one solution is to replace first loop by a DO/WHILE, but is it really normal ? where is my wrong ? Thank's for help denis |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Problem with "Task.StartDate" in Outlook.dll | JOTHA | Bug Reports | 9 | 09-19-2008 03:19 PM |
| TabControl "addControl" problem. | burd27 | Questions & Help Needed | 4 | 04-20-2008 09:42 AM |
| Problem with Serial. ("before loop" error) | jesb4ppc | Questions & Help Needed | 3 | 02-15-2008 06:41 PM |
| calling the device's "Programs" or "settings" screens | HarleyM | Questions & Help Needed | 0 | 12-05-2007 03:59 AM |
| SetUpBuilder Problem - "Build Cabs first" | dhillinmkewi | Questions & Help Needed | 1 | 07-27-2007 09:20 AM |