I mean an image i got in the solution
Printable View
I mean an image i got in the solution
in the solution? what do you mean? you mean you have the image in a resource file?Quote:
Originally posted by Aerials
I mean an image i got in the solution
i added it via add-existing itemQuote:
Originally posted by MrPolite
in the solution? what do you mean? you mean you have the image in a resource file?
I believe you still have to use the path to load it. Adding a misc file to the solution in .NET is kind of like adding a related document in VB6. It just associates it with the solution don't doesn't really provide anymore functionality.
by just using the path it wont load on other comps and it crashes the program :(Quote:
Originally posted by Edneeis
I believe you still have to use the path to load it. Adding a misc file to the solution in .NET is kind of like adding a related document in VB6. It just associates it with the solution don't doesn't really provide anymore functionality.
i tried
crashes?! hmm!!!Quote:
Originally posted by Aerials
by just using the path it wont load on other comps and it crashes the program :(
i tried
post your code
this works for me:
PictureBox1.Image = New Bitmap("C:\pic.bmp")
also this:
PictureBox1.Image = Image.FromFile("c:\test.bmp"):rolleyes:
I used Mr. P's way
umm you wanted to load the image in the app's folder:
VB Code:
Dim path As String = Application.StartupPath path = System.IO.Path.Combine(path, "ImageName.bmp") PictureBox1.Image = New Bitmap(path)