Hi !
could you help me with this code ?
Thanks !
i want display
rx = 13
ry = 13
rx = 15
ry = 18
could you help me with this code ?
Thanks !
Strict Type Tpoint Field x Field y Function Create:tpoint (x,y, who:Tinfo) Local t:tPoint = New Tpoint t.x = x t.y = y ListAddLast who.MyList, t Return t End Function End Type Type TInfo Field MyList:Tlist = CreateList() Field Link_Mylist : TLink = MyList.FirstLink() Field Value : Int Function Create:TInfo (Value : Int) Local m:TInfo = New TInfo m.Value = Value Return m End Function Method Add_point (x:Int, y:Int) tpoint.Create (x,y, Self) End Method Method Print_point_coordonates() Local rx, ry Link_Mylist = Link_Mylist. NextLink() If Link_Mylist = Null Then rx = -1 ry = -1 Else ' how to acces to the next tpoint x and y stored into the liste (print it or modify the value) ' rx = ? ' ry = ? End If DebugLog "rx = " + String (rx) DebugLog "ry = " + String (ry) End Method End Type Local t:TInfo t = tInfo.Create (10) t.Add_point (13,13) t.Add_point (15,18) t.Print_point_coordonates () t.Print_point_coordonates ()
i want display
rx = 13
ry = 13
rx = 15
ry = 18