Resources

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • =?Utf-8?B?UmljYXJkbyBGdXJ0YWRv?=

    Resources

    I want to insert an image in a resource that i have in my project.
    My resource is:
    my.Resources.Re sCeph
    but i'm not beeing able to insert the image in that resource.
    The code i'm using is this:

    Dim img As Image
    Dim rsxw As ResXResourceWri ter
    Dim strImg As String = "XPTO"

    img = Image.FromFile( strImageLocatio n)
    rsxw = New ResXResourceWri ter("ResCeph.re sx")
    rsxw.AddResourc e(strImg , img)
    rsxw.Close()


    I've been trying to find a way to change the line
    rsxw = New ResXResourceWri ter("ResCeph.re sx")
    into something like
    rsxw = New ResXResourceWri ter(my.Resource s.ResCeph)
    but i'm not being able to do it.

    Is there any way to insert the image in the resource
    my.Resources.Re sCeph
    ?

    My thanks in advanced

  • Armin Zingler

    #2
    Re: Resources

    "Ricardo Furtado" <RicardoFurtado @discussions.mi crosoft.comschr ieb
    Is there any way to insert the image in the resource
    my.Resources.Re sCeph
    ?
    Resources are designed to be read-only. However, you can write new resx
    files and link them the next time you build an assembly. If you need
    dynamic data, use a database or a configuration file or whatever.


    Armin

    Comment

    Working...