ombre
New Member
Posts: 9
|
Post by ombre on Dec 19, 2021 10:49:33 GMT -5
I work in win 10 with lb 4.5.1
After running the following program and ending it normally, why must I «kill» it?
rem C:\Users\Utilisateur\Documents\Liberty Basic\Jeux\Lettres
nomainwin
BackgroundColor$="lightgray"
WindowWidth=320:WindowHeight=375
UpperLeftX=DisplayWidth /2 - WindowWidth /2
UpperLeftY=(DisplayHeight /2 - WindowHeight /2) -50
button#main.ButFin,"Quit",[Quit],ul,30,200
graphicbox#main.GrafMot,25,5,250,240
graphicbox#main.GrafLettres,25,260,250,50
open "Trouve les mots" for window as #main
#main.GrafMot,"backcolor 220 160 75"
#main.GrafLettres,"backcolor 200 180 75"
#main,"trapclose [Quit]"
call sMots
wait
sub sMots
#main.GrafMot,"font Times_New_Roman 15"
h=int(rnd(1)*3)+1
for x=1 to h
read nb,l1$,l2$,l3$,l4$,l5$
next x
#main.GrafMot,"place 1 20":#main.GrafMot,"line 1 20 5 20" 'Premier
for x=1 to nb-1
#main.GrafMot,"place "; x*35;" 20":#main.GrafMot,"line 5 20 10 20" 'Les autres
next x
#main.GrafLettres,"font Calibri 20"
#main.GrafLettres,"place 1 30":#main.GrafLettres,"|";l1$
#main.GrafLettres,"place 21 30":#main.GrafLettres,"|";l2$
#main.GrafLettres,"place 41 30":#main.GrafLettres,"|";l3$
#main.GrafLettres,"place 61 30":#main.GrafLettres,"|";l4$
#main.GrafLettres,"place 81 30":#main.GrafLettres,"|";l5$
data 3,"T","S","E","",""
data 4,"L","C","A","M",""
data 5,"F","G","H","I","J"
end sub
[Quit]
close #main: end
|
|
|
Post by tsh73 on Dec 19, 2021 11:31:18 GMT -5
tried it a few times on Win 10 No pieces left on exit so far.
|
|
|
Post by Brandon Parker on Dec 19, 2021 15:21:57 GMT -5
I can confirm Anatoly's findings. The little program runs perfectly fine and closes as expected.
{:0)
Brandon Parker
|
|
|
Post by Rod on Dec 19, 2021 15:27:33 GMT -5
One possibility is that you are in the debugger and quit while you are in the sub. That won't work because your [quit] branch won't be found. Tell us what exact steps you take to create the problem with the program.
|
|
ombre
New Member
Posts: 9
|
Post by ombre on Dec 20, 2021 10:27:43 GMT -5
This is the message I get in the «Kill Basic Programs»:
C;\users\Utilisateur\OneDrive\Documents\Liberty Basic\Jeux\LettresT.bas
|
|
|
Post by Rod on Dec 20, 2021 11:46:23 GMT -5
Ok, that is a known bug, you can ignore the kill list message. If the window has closed and the mainwin is closed the program has ended. Despite what the kill list says.
|
|