Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Embedded Resources in base class [modified]

Embedded Resources in base class [modified]

Scheduled Pinned Locked Moved ASP.NET
csshardwarelearning
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    Fayu
    wrote on last edited by
    #1

    I have two projects: 1) MyProject1 2) MyProject2 Directory Structure MyProject1 -Images ---BaseControl ------img1.gif ------img2.gif ------img3.gif -Css ---BaseControl ------StyleSheet.css -Controls ---BaseControl.cs - derived from CompositeControl ---Derived1.cs - derived from BaseControl ---Derived11.cs - derived from BaseControl ---Derived12.cs - derived from BaseControl MyProject2 -Controls ---Derived4.cs - derived from BaseControl Assembly.cs for MyProject1 NOTE: Image is set as an embedded resource [assembly: WebResource("MyProjects1.Images.BaseControl.gif", "img/gif")] To get the link to the WebResource, I do the following: myImgControl.ImageUrl = this.GetImageUrl("MyProject1.Images.BaseControl.gif"); This works fine with Derived1, Derived11 and Derived12 controls since the embedded resource is available to their parent. However, Derived4 control cannot find the images because the 'MyProject1.Images.BaseControl.gif' is not part of its embedded resource. Let me know if you need anymore info. Thanks.

    modified on Wednesday, August 11, 2010 6:43 PM

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups