Hy!
I wrote a little image merger script, but when i run it I saw, I get a wrong destination folder. I tried to stop the debuging and click to close button but for 10 seconds couldn't close the program.
First: why couldn't stop the debugging when i clicked the stop button?
Second: How can I implement a cancel method in this script?
Thank you for help
I wrote a little image merger script, but when i run it I saw, I get a wrong destination folder. I tried to stop the debuging and click to close button but for 10 seconds couldn't close the program.
First: why couldn't stop the debugging when i clicked the stop button?
Second: How can I implement a cancel method in this script?
B4X:
Sub App_Start
frmMain.Show
ctrlExProgBar.New1("frmMain",0,200,240,25)
ctrlExProgBar.Minimum=1
ctrlExProgBar.Maximum=804
bmpExMerge.New2(2048,1237)
rectEx1.New1(0,0,1024,1237)
rectEx2.New1(1024,0,1024,1237)
drawEx1.New2(bmpExMerge.Value)
End Sub
Sub btnStart_Click
x=1
For i=1 To 804
bmpEx1.New1(AppPath&"\images\" & i &".jpg")
bmpEx2.New1(AppPath&"\images\" & i+1 &".jpg")
drawEx1.DrawImage(bmpEx1.Value,rectEx1.Value,rectEx1.Value,False)
drawEx1.DrawImage(bmpEx2.Value,rectEx1.Value,rectEx2.Value,False)
bmpExMerge.SaveImage(AppPath&"\merged\"&x&".jpg","J")
i=i+1
x=x+1
ctrlExProgBar.Value=i
Next
Msgbox("Finish merging")
End Sub
Thank you for help