et ce code là, il marche chez toi ?
Code : Tout sélectionner
If CreateFile(0,"C:\cds.dat")
WriteStringN(0,"bouton 1,10,10,100,30")
WriteStringN(0,"bouton 2,10,50,120,40")
WriteStringN(0,"bouton 3,10,90,80,60")
CloseFile(0)
EndIf
If OpenWindow(0,0,0,640,480,#PB_Window_SystemMenu,"MaFenetre")
If CreateGadgetList(WindowID(0))
If ScrollAreaGadget(0, 20, 100, 500, 285, 285, 570, 10, #PB_ScrollArea_BorderLess )
If OpenFile(0,"C:\cds.dat")
While Not Eof(0)
l.s = ReadString(0)
t.s = StringField(l,1,",")
x.l = Val(StringField(l,2,","))
y.l = Val(StringField(l,3,","))
w.l = Val(StringField(l,4,","))
h.l = Val(StringField(l,5,","))
ButtonGadget(#PB_Any, x, y, w, h, t )
Wend
CloseFile(0)
EndIf
CloseGadgetList()
EndIf
EndIf
Repeat
EventID = WaitWindowEvent()
Until EventID = #PB_Event_CloseWindow
EndIf
End