Start all the specified folder image file name to the list box, list box is empty, no displayed a list box picture file in turn
List box lb_notice counter i_notice
The timer event is simple code:
If lb_notice. Totalitems () & lt;> 0 then
P_notice. Picturename="./PIC/" + lb_notice. The text (i_notice)
If i_notice & lt; Lb_notice. Totalitems () then
I_notice + +
The else
I_notice=1
End the if
End the if
The timer cycle program flash back after more than 10000 times,
O masters teach
The above code originally written in other programs, but after more than 10000 times, memory continues to grow, until the system is stuck,
CodePudding user response:
Cycle after a certain number of times to try, to reset the window,CodePudding user response:
Estimation is the bug of pb itself, you try to perform after ten thousand time, turn off the window of the present contains pictures, and then try to use the open openCodePudding user response:
"Select" button code:Lb_image=gf_open_pic (p_1, lb_image)
P_1. Setpicture (lb_image)
//* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
"Remove" button code:
P_1. Picturename='
P_1. Picturename='//(twice)
Setnull (lb_image)
CodePudding user response:
Before assigning p_notice. Picturename empty, seemingly every assignment accumulation into memory, estimates that it is for this reasonCodePudding user response:
Through the dw paint to paint won't and can cooperate with better effect to use multithreading