English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I want to change the piture property for an image in vb6
how do I do this?
I am trying this:
Image1.Picture = "C:\Documents and Settings\Owner\My Documents\3-D PICTURE.bmp"

It says Type Mismatch

Help me please!

2006-09-21 14:27:38 · 3 answers · asked by James R 2 in Computers & Internet Programming & Design

3 answers

It is not expecting a file name. It is expecting a handlke for a picture. So you have to load a file and convert in to picture
Read more for exact syntax.

Picture1.Picture = LoadPicture(Dir1.Path + "\" + File1.filename)

2006-09-21 14:38:04 · answer #1 · answered by Dr M 5 · 1 0

You cannot change that technique. You should use the 'LoadPicture' function native in VB.

Example:
Image1.Picture = LoadPicture("C:\Documents and Settings\Owner\My Documents\3-D PICTURE.bmp")

For more free VB codes, visit: http://smartcoder.awardspace.com


KaBalweg
http://smartcoder.awardspace.com

2006-09-21 15:19:34 · answer #2 · answered by dabsani 3 · 0 0

this may well be a tiny application, stick a timer on the variety, double-left click on the variety, delete each thing, paste this in the time of and alter the path call of the image to a minimum of one among your own, you ought to no longer want any variables. i've got advised this timer to run the piece of code it has each 0.5 a 2nd, making the image go diagonal. inner maximum Sub Form_Load() Picture1.image = LoadPicture("C:records and SettingsuserDesktopYahooAnswersMovin... Timer1.era = 500 end Sub inner maximum Sub Timer1_Timer() Picture1.Left = Picture1.Left + one hundred Picture1.precise = Picture1.precise + one hundred end Sub

2016-10-15 06:57:44 · answer #3 · answered by leong 4 · 0 0

fedest.com, questions and answers