Link to home
Start Free TrialLog in
Avatar of perkster
perkster

asked on

Type mismatch loading image from file

Whenever I run the following command:

Image1.Picture = App.Path & "\" & ListView1.SelectedItem.ListSubItems(3).Text

I get a type mismatch error on the "&" symbol.

Can someone help me figure out how to load an Image.picture with a file on my hard drive?
ASKER CERTIFIED SOLUTION
Avatar of aikimark
aikimark
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Yup...points to aikimark

The picture property is a picture object, not a string...the file path is a string, so you get a type mismatch.

To get a picture object, you need to "convert" the string, which is what LoadPicture does.