943,652 Members | Top Members by Rank

Ad:
You are currently viewing page 1 of this multi-page discussion thread
Jun 28th, 2007
0

picture box

Expand Post »
hello, i am using picture box, and coding on form load

P1.Picture = "D:\My Document\My Pictures\Display Picture\ICE.BMP"

why it gives "TYPE MISSMACH" Error.

plz reply soon.

Yasir
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
yasirfarid is offline Offline
7 posts
since Jun 2007
Jun 28th, 2007
0

Re: picture box

Click to Expand / Collapse  Quote originally posted by yasirfarid ...
hello, i am using picture box, and coding on form load

P1.Picture = "D:\My Document\My Pictures\Display Picture\ICE.BMP"

why it gives "TYPE MISSMACH" Error.

plz reply soon.

Yasir
The correct syntax is

P1.Picture = LoadPicture("C:\MyPict.bmp")

thanks to veena
Reputation Points: 10
Solved Threads: 9
Junior Poster
AV Manoharan is offline Offline
166 posts
since Jun 2007
Jun 28th, 2007
0

Re: picture box

Hi Manoharan..

Why Thank Me....???

-Vee
Reputation Points: 84
Solved Threads: 140
Posting Shark
QVeen72 is offline Offline
923 posts
since Nov 2006
Jun 28th, 2007
0

Re: picture box

Click to Expand / Collapse  Quote originally posted by QVeen72 ...
Hi Manoharan..

Why Thank Me....???

-Vee
Don't you remember your own answers in this forum?
But I do.

regards
AV Manoharan
Reputation Points: 10
Solved Threads: 9
Junior Poster
AV Manoharan is offline Offline
166 posts
since Jun 2007
Jul 17th, 2007
0

Re: picture box

The correct syntax is

P1.Picture = LoadPicture("C:\MyPict.bmp")

thanks to veena
yeah but what about if i want to load an impage from the internet? and if the image isn't bmp? It says file/path access error... could someone help me?
Reputation Points: 10
Solved Threads: 0
Newbie Poster
edu2004eu is offline Offline
5 posts
since Jul 2007
Jul 17th, 2007
0

Re: picture box

Quote ...
yeah but what about if i want to load an impage from the internet?
Sorry I don't know what is an impage...

Quote ...
and if the image isn't bmp? It says file/path access error... could someone help me?
Use a Common Dialog Box

CommonDialog1.Filter = "Picture Files (*.bmp;*.jpg;*.gif)|*.bmp;*.jpg;*.gif;|"
CommonDialog1.ShowOpen
Image1.Picture = LoadPicture(CommonDialog1.FileName)
Last edited by jireh; Jul 17th, 2007 at 8:32 pm.
Reputation Points: 11
Solved Threads: 49
Posting Whiz
jireh is offline Offline
316 posts
since Jul 2007
Jul 18th, 2007
0

Re: picture box

i meant image... not impage... sorry for that typo

well if the image isn't stored in the local PC, but is in a web site... for example if i want this http://www.daniweb.com/forums/myimag...tons/reply.gif displayed in a picturebox, how do i do it...?
Reputation Points: 10
Solved Threads: 0
Newbie Poster
edu2004eu is offline Offline
5 posts
since Jul 2007
Jul 18th, 2007
0

Re: picture box

Hi edu,

use a "WebBrowser" Control and Navigate it to the url. check this

WebBrowser1.Navigate2 "http://www.whateverwebsite.com/imagesfolder/myimage.jpg"

Regards
Veena
Reputation Points: 84
Solved Threads: 140
Posting Shark
QVeen72 is offline Offline
923 posts
since Nov 2006
Jul 18th, 2007
0

Re: picture box

Thanks, it worked
Reputation Points: 10
Solved Threads: 0
Newbie Poster
edu2004eu is offline Offline
5 posts
since Jul 2007
Jul 19th, 2007
0

Re: picture box

me.picture(app.path&"name with extention of the pictur")
Reputation Points: 10
Solved Threads: 0
Newbie Poster
syamkumard is offline Offline
1 posts
since Jul 2007

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Visual Basic 4 / 5 / 6 Forum Timeline: image
Next Thread in Visual Basic 4 / 5 / 6 Forum Timeline: Split PDF using Vb6





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC