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

How to embed resource in ASP.Net 2.0 web application?

P: n/a
Hello Developers,

It may sound like a stupid question, but how to embed a resource in ASP.Net
2.0 web application?
I mean, without using a separate library. There is no "build action"
property.

Thanks,

Tomasz J
Jun 8 '07 #1
Share this Question
Share on Google+
8 Replies


P: n/a
"Tomasz J" <oe****@nospam.nospamwrote in message
news:e3**************@TK2MSFTNGP03.phx.gbl...
It may sound like a stupid question, but how to embed a resource in
ASP.Net 2.0 web application?
Google is your friend:
http://www.google.co.uk/search?sourc...ed+resource%22
--
http://www.markrae.net

Jun 8 '07 #2

P: n/a
>It may sound like a stupid question, but how to embed a resource in
>ASP.Net 2.0 web application?

Google is your friend:
http://www.google.co.uk/search?sourc...ed+resource%22
By embed I mean: make a part of the executing assembly dll file.
Trust me Mark, it only appears to be an easy to answer question.
Of course, unless you know the answer, other that the above one - which I
doubt.

Tomasz J
Jun 8 '07 #3

P: n/a
"Tomasz J" <oe****@nospam.nospamwrote in message
news:ON**************@TK2MSFTNGP05.phx.gbl...
By embed I mean: make a part of the executing assembly dll file.
Is this not what you're looking for, then: ?
http://aspalliance.com/726
--
http://www.markrae.net

Jun 8 '07 #4

P: n/a
"Mark Rae" <ma**@markNOSPAMrae.netwrote in message
news:O$****************@TK2MSFTNGP04.phx.gbl...
"Tomasz J" <oe****@nospam.nospamwrote in message
news:ON**************@TK2MSFTNGP05.phx.gbl...
>By embed I mean: make a part of the executing assembly dll file.

Is this not what you're looking for, then: ?
http://aspalliance.com/726
Nope, it is not the answer. There are plenty of examples showing how to
embed resource in some control library and then use from Web Application,
but it is not the same thing.

Why do I want to embed resource in Web Application? I need it for my user
control and user controls (.ascx), as opposed to web controls, must be part
of the application. I can, of course create a separate dll for this
resource, but it is nonsense.

Tomasz J
Jun 8 '07 #5

P: n/a
"Tomasz J" <oe****@nospam.nospamwrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl...
Why do I want to embed resource in Web Application? I need it for my user
control and user controls (.ascx), as opposed to web controls, must be
part of the application. I can, of course create a separate dll for this
resource, but it is nonsense.
Hmm - OK...

Have you considered ILMerge instead...?
http://research.microsoft.com/~mbarnett/ILMerge.aspx
--
http://www.markrae.net

Jun 8 '07 #6

P: n/a

"Mark Rae" <ma**@markNOSPAMrae.netwrote in message
news:u3**************@TK2MSFTNGP06.phx.gbl...
"Tomasz J" <oe****@nospam.nospamwrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl...
>Why do I want to embed resource in Web Application? I need it for my user
control and user controls (.ascx), as opposed to web controls, must be
part of the application. I can, of course create a separate dll for this
resource, but it is nonsense.

Hmm - OK...

Have you considered ILMerge instead...?
http://research.microsoft.com/~mbarnett/ILMerge.aspx
Yes, there are also other solutions, like Apache Wicket, but I am still
hoping to find an easier way.
Another solution is to move back to "Web Project".

Tomasz J
Jun 8 '07 #7

P: n/a
Hi Tomasz,

For the ASP.NET 2.0 application, do you mean the default "Web Site" project
model?

For ASP.NET 2.0 web site application, it by default do not precompile and
generate dll at development time(without precompilation) comparing to the
ASP.NET 1.X/VS 2003 web project. However, for localization resource, it
provide much enhanced interfaces to manipulate them at design-time. You can
add resources (as resx files) as either "GlobalResource" or
"LocalResource", global resource can be put into the "App_GlobalResources"
folder of your ASP.NET 2.0 project while local resource can be put into a
"App_LocalResources" folder (can be created for each sub folder). The VS
2005 resource designer can let you add different kinds of resource items
into it(such as string, image ,file ,......)
#Resources and Localization in ASP.NET 2.0
http://msdn.microsoft.com/msdnmag/is...asicInstincts/

#ASP.NET Web Page Resources Overview
http://msdn2.microsoft.com/en-us/library/ms227427.aspx

Is this what you want? If you have any further questions, please feel free
to post here.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.



Jun 11 '07 #8

P: n/a
Hi Tomasz,

Have you any further questions on this? If there is anything else need
help, please feel free to post here.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.

Jun 13 '07 #9

This discussion thread is closed

Replies have been disabled for this discussion.