Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

C# ASP.NET AssemblyInfo.cs - embedded .JS resides inside a folder - how do I specify the web resource path?

Posted on 2016-08-29
1
Medium Priority
?
122 Views
Last Modified: 2016-08-29
[assembly: WebResource("DealerSocket.Web.WebForms.Controls.CSharp.datePickerSC.js", "text/javascript")]

Open in new window


The above works fine if the datePicker.js file is in the "root" or at the same level as the webcontrol.cs file.

But how does the WebResource path change if the .JS file is inside a folder?

[assembly: WebResource("DealerSocket.Web.WebForms.Controls.CSharp  <<< folder path >>>datePickerSC.js", "text/javascript")]

Open in new window



This

root

vs this:

folder path
0
Comment
Question by:Tom Knowlton
1 Comment
 
LVL 5

Accepted Solution

by:
Tom Knowlton earned 0 total points
ID: 41775476
http://www.codeproject.com/Articles/217176/Embedding-and-inlining-resources-in-ASP-NET-Web-Co

Apparently it is the "dot" separator:

Taken from the above link:

The second part is the path within the project folder structure. In our case, the files are placed in the Resources folder in the root of the project; therefore the part of the name is just Resources. In more complex structures, a dot is used as the path separator. The third and last part is the file name, including the extension. In the above example, it’s FlagBlue.png.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question