[Gambas-user] Project crash due Textarea selection

T Lee Davidson t.lee.davidson at gmail.com
Wed Oct 7 01:52:14 CEST 2020


On 10/6/20 1:23 PM, pinglix via User wrote:
> If I put textarea.line = 0 program crashes immediately so I think Line is one-indexed.

With a form having only a TextArea and a Timer, the following code does not crash.

Public Sub Form_Open()

   TextArea1.Line = 0

End

Public Sub Timer1_Timer()

   TextArea1.Insert("This is line #" & TextArea1.Line & "\n")

End


If you remove the Form_Open event handler, you will see that line numbers start with zero.


-- 
Lee


More information about the User mailing list