Index problem in the IF statement

markus

Member
Licensed User
Hi all,

I have a problem with the following statements.
B4X:
[FONT="Courier New"]Sub btnRechnen_Click
     IF label5.text="......" then
        MsgBox("Standort auswählen")
     Else if
        for i=0 to Table1.RowCount-1
        ……………
        …………[/FONT]
Is the value of label5.text=”......” the program works fine.
Is there an other value in label5.text (in my case a numeric value)
the program stops.

IF label5.text“……“ then
Error description:
Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index​

any idea?

thnx for your help
Markus
 

markus

Member
Licensed User
Hi Erel

yes, yes, mh…….. i should know this…, sorry.

Thanks a lot for your help

Regard
Markus
 
Top