|
-
Oct 6th, 2000, 04:17 AM
#1
Thread Starter
New Member
Hi.
Does anybody know how to find out when a picture is loaded? (without looking)
I have this:
With Start
.Visible = False
.Stretch = False
.Picture = LoadPicture(lp)
End With
But I need to know when the picture is finished loading, and... but this is not important.. somehow wait until the task is finished before doing something else. Any Ideas?
Thanks
-
Oct 6th, 2000, 06:14 AM
#2
A DoEvents might do the trick.
Code:
With Start
.Visible = False
.Stretch = False
.Picture = LoadPicture(lp)
DoEvents
Msgbox "Picture done"
End With
-
Oct 6th, 2000, 06:16 AM
#3
transcendental analytic
The picture property returns a handle when it's loaded with a stdpicture so you check for the handle
Code:
do until .picture
doevents
loop
Use  
writing software in C++ is like driving rivets into steel beam with a toothpick.
writing haskell makes your life easier:
reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.
-
Oct 6th, 2000, 06:47 PM
#4
Thread Starter
New Member
Thanks. I tried the:
DoEvents
Msgbox "Picture done"
End With
before I posted anything here, and that worked fine... until it had to load two pictures.. like this:
frmPage.Picture1.Picture = LoadPicture("d:/cata/blue.bmp")frmPage.Picture2.Picture = LoadPicture("d:/cata/red.bmp")frmPage.Picture3.Picture = LoadPicture("d:/cata/green.bmp")
DoEvents
Msgbox "Picture done"
then for some reason it continued the execution of the rest of the code before all the pictures was loaded.
the
do until .picture
doevents
loop
works fine...
thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|