By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
432,306 Members | 1,657 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 432,306 IT Pros & Developers. It's quick & easy.

Embedding WebResources: multiple images in folder

P: n/a
Hello,

i am embedding System.Web.UI.WebResources in my C# Class via:
[assembly: System.Web.UI.WebResource("ExtJS.yui-ext.css", "text/css")]

I use this resource with:

Page.Header.Controls.Add(new LiteralControl("<link href='"ExtJS.yui-
ext.css"' rel='stylesheet' type='text/css' />"));

The css file is embedded fine into my website, but it does not detect
the images in my folder 'ExtJS.images'

I am refering to the images in the CSS file like this:

.extjs{background:#fff url(<
%=WebResource("ExtJS.images.default.form.text-bg.gif")%>) repeat-x 0
0;}
But this does not work. What do I do wrong?
Do I have to register the images as WebResources in the same way I
registered the css file ([assembly:
System.Web.UI.WebResource("ExtJS.yui-ext.css", "text/css")]) too?
If yes... where and how?
And another question...
Its not very clear to my why I have to register the WebResources as
assembly. Does it have any special reason?
Regards,

Martin
Jan 16 '08 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.