Login Register


[Help] Codedom and recource file filter_list
Author
Message
[Help] Codedom and recource file #1
Hi HC Biggrin

I have little problem with my application.

I created an application that use codedom to compile another application and Add picture in Recource and it works good.

But how I invoke that image in my application.

I tried this but it does not work.

Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim resslika As New System.Resources.ResourceManager("an.png", System.Reflection.Assembly.GetExecutingAssembly) PictureBox1.Image = resslika.GetObject("an.png") End Sub

Reply

RE: [Help] Codedom and recource file #2
Wait...you want the a picture from your resources to be set to a Picturebox when you press a button?

Reply

RE: [Help] Codedom and recource file #3
(06-04-2012, 12:31 PM)Jacob Wrote: Wait...you want the a picture from your resources to be set to a Picturebox when you press a button?

Yes, exactly

Reply

RE: [Help] Codedom and recource file #4
lol, why are you doing this?

Code:
PictureBox1.Image = Image.FromHbitmap(My.Resources.claw.GetHbitmap)

The image I had in resources was "claw.png", therefore in resources referenced as "claw"
ArkPhaze
"Object oriented way to get rich? Inheritance"
Getting Started: C/C++ | Common Mistakes
[ Assembly / C++ / .NET / Haskell / J Programmer ]

Reply

RE: [Help] Codedom and recource file #5
Don't work but Thanks anyway.

"resource is not member of My" in codedom

Reply

RE: [Help] Codedom and recource file #6
I'm not talking about CodeDom... Why do you need CodeDom to display an image from resources inside a picturebox? I didn't post any CodeDom in my example. It does work, I don't post solutions that don't work.
ArkPhaze
"Object oriented way to get rich? Inheritance"
Getting Started: C/C++ | Common Mistakes
[ Assembly / C++ / .NET / Haskell / J Programmer ]

Reply

RE: [Help] Codedom and recource file #7
What he wants is his codedom generated executable to have an image from resources. I looked as his code, his main form is a form with one big button. When pressed, it generates an executable with buttons and other controls alike.


To OP, you're better off uploading the image to your server or imgur/tinypic. Then grabbing the image directly and setting it.

Reply

RE: [Help] Codedom and recource file #8
Actually I'm working on crypter, which uses image data storage method. Or Stenography

Reply

RE: [Help] Codedom and recource file #9
Actually I'm working on crypter, which uses image data storage method. Or Stenography

Reply







Users browsing this thread: