Adding resource to a file!

  • Thread starter Thread starter CSharper
  • Start date Start date
C

CSharper

Just curious, When you are in IDE, you are able to add a resource to
the project through resource tab. Later this resource can be accessed
using the resource manager. One good thing about this approach is
that, the resource file is build into the exe and using resource
manager you can later get already added resource file back.
Now is it possible to do that through programatically? I want to add a
resource to the default resource (if I use resource writer then I need
to explicitly specify the resource file and that resource file need to
be distributed along with the exe) during execution on the fly, is it
possible?

Thanks.
 
Just curious, When you are in IDE, you are able to add a resource to
the project through resource tab. Later this resource can be accessed
using the resource manager. One good thing about this approach is
that, the resource file is build into the exe and using resource
manager you can later get already added resource file back.
Now is it possible to do that through programatically? I want to add a
resource to the default resource (if I use resource writer then I need
to explicitly specify the resource file and that resource file need to
be distributed along with the exe) during execution on the fly, is it
possible?

Thanks.

I do not understand what you ask, you cannot modify the assembly from
"regular code" , you could try to use CodeCOM or something similar,
maybe there is a tool that allow you to do that , I know of none
though.
 
I do not understand what you ask, you cannot modify the assembly from
"regular code" , you could try to use CodeCOM or something similar,
maybe there is a tool that allow you to do that , I know of none
though.

Thank you I think I figured it out. I compiled the code with /resource
option and was able to get it into my exe to use it.
 
Back
Top