sharky12345
Well-known Member
- Joined
- Aug 5, 2010
- Messages
- 3,422
- Office Version
- 2016
- Platform
- Windows
I'm using this to load an image into an Image Control on a Userform;
The image path is stored in TextImage.
I'm getting an error on some occasions, but this doesn't happen all of the time - I'm getting 'Error 424 - Object Required', but I don't understand what it means and what's causing it. It happens with different files and sometimes the same file will work and then it won't, so it can't be file specific.
Anyone got an idea?
Code:
With Img
.Picture = LoadPicture(TextImage.Value)
.PictureSizeMode = fmPictureSizeModeStretch
End With
Me.Repaint
The image path is stored in TextImage.
I'm getting an error on some occasions, but this doesn't happen all of the time - I'm getting 'Error 424 - Object Required', but I don't understand what it means and what's causing it. It happens with different files and sometimes the same file will work and then it won't, so it can't be file specific.
Anyone got an idea?