Setting the path of image file..In Code
I'm been a while since i use this VB2008, now i forgot the right syntax
Can you help me how can i put a code on how to set the path of an image..
Ex:
Code:
MainPicture.Image = Image.FromFile("D:\A.RODNEY DOCUMENTS\Microsoft Basic\Gasoline Station DB\Gasoline Station DB\Pics\MainMenuSignUp(203,252).png")
something like that,
SO hard that to transfer my project files into the other PC without VB2008
and not working the path cause they need to change it the path again for changes.
what i want is:
Is there a code for automatically read the specific path so that can transfer my project files in other drive or PC without changing the path...
Re: Setting the path of image file..In Code
Quote:
Is there a code for automatically read the specific path so that can transfer my project files in other drive or PC without changing the path...
the easiest way to do that is to add the image to your project as a resource. Then you can access the image in code using My.Resource.resourcename
kevin
Re: Setting the path of image file..In Code
Oh, That's it...
I'll remeber now...
using the resource
I Forgot that....
Hope this work..