473,504 Members | 13,746 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Can I run ASP.NET app from different virtual site?

Hi

I have a ASP.NET 1.1 app that is compiled to say "APP1.dll" and APP1 is the name of the virtual directory. I want to be able to have a staging site where I can just copy the files over to another virtual directory called APP2. When I first tried it I got Resource Manager errors. I tried just renaming the main dll and resource file dll's to APP2 and then got "Comparing the assembly name resulted in the mismatch: NAME" error. If the files run in the same virtual directory name that they were compiled under, everything is fine. What's the correct way to do this

Thanks
Chris
Nov 17 '05 #1
7 1284
"Chris" <st******@kubota-kma.com> wrote in message
news:B9**********************************@microsof t.com...
Hi,

I have a ASP.NET 1.1 app that is compiled to say "APP1.dll" and APP1 is

the name of the virtual directory. I want to be able to have a staging site
where I can just copy the files over to another virtual directory called
APP2. When I first tried it I got Resource Manager errors. I tried just
renaming the main dll and resource file dll's to APP2 and then got
"Comparing the assembly name resulted in the mismatch: NAME" error. If the
files run in the same virtual directory name that they were compiled under,
everything is fine. What's the correct way to do this?

I do this all the time, with no resource manager problems. Try again, from
scratch, and tell us what resource manager problems you're having.
--
John

Nov 17 '05 #2
Hi John,

I get:

[ArgumentException: ResourceManager base name should not end in
resources. It should be similar to MyResources, which the
ResourceManager can convert into MyResources.<culture>.resources; for
example, MyResources.en-US.resources.]
System.Resources.ResourceManager.CommonSatelliteAs semblyInit() +195
System.Resources.ResourceManager..ctor(String baseName, Assembly
assembly) +55
SupplierLink.UtilityBiz..ctor() +78
SupplierLink.Login..ctor() +100
_ASP.Login_aspx..ctor() +6

I have a default resource file which is compile into the main dll and I
have 2 Satellite dlls for Japanese and Spanish. It all works fine when
it's under the same site name as it was developed under. Should I be
able to just use the same files on the the same server but under a
different virtual directory. It looks like this:

IIS
APP1
bin
APP1.dll
es
APP1.resources.dll
ja
APP1.resources.dll

New site that gets errors:

IIS
APP2
Bin
APP1.dll
es
APP1.resources.dll
ja
APP1.resources.dll

The virtual site name is the only difference. It's the same files just
copied to a different directory and with a different virtual site name.
Should I be able to do this?

I'm using Code-Behind pages and it's not strongly named and haven't done
anything with the GAC...

Thanks,
Chris
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 17 '05 #3
"Chris Strobel" <st******@kubota-kma.com> wrote in message
news:#T**************@TK2MSFTNGP12.phx.gbl...
Hi John,

I get:

[ArgumentException: ResourceManager base name should not end in
resources. It should be similar to MyResources, which the
ResourceManager can convert into MyResources.<culture>.resources; for
example, MyResources.en-US.resources.]
System.Resources.ResourceManager.CommonSatelliteAs semblyInit() +195
System.Resources.ResourceManager..ctor(String baseName, Assembly
assembly) +55
SupplierLink.UtilityBiz..ctor() +78 SupplierLink.Login..ctor() +100
_ASP.Login_aspx..ctor() +6

Ok, so maybe the SupplierLink.UtilityBiz constructor is instantiating a
ResourceManager and specifying something for the baseName parameter which
ends in ".resource"? In that case, "don't do that".
--
John
Nov 17 '05 #4
I think I have it figured out. Is there a way to instantiate the Resource Manager without having to name the assembly? I was doing it like this:

Private mobjResourceManager As ResourceManager = New ResourceManager("APP1.Resources", GetType(Header).Assembly)

I get errors if I don't include the APP1. In some examples I've seen they just have the name of the Resource which is "Resources.resx". I was trying to share the same class file in 2 different projects which gets compiled into each project.

I can do something like this:

Private mobjResourceManager As ResourceManager = New ResourceManager(Reflection.Assembly.GetExecutingAs sembly.GetName.Name & ".Resources", GetType(Header).Assembly)

and that will make it work, but it seems like I shouldn't have to from other examples.

Thanks,
Chris
Nov 17 '05 #5
Didn't the error message say you should _not_ use the .resources extension?

--
John
"Chris" <an*******@discussions.microsoft.com> wrote in message
news:09**********************************@microsof t.com...
I think I have it figured out. Is there a way to instantiate the Resource Manager without having to name the assembly? I was doing it like this:
Private mobjResourceManager As ResourceManager = New ResourceManager("APP1.Resources", GetType(Header).Assembly)
I get errors if I don't include the APP1. In some examples I've seen they just have the name of the Resource which is "Resources.resx". I was trying
to share the same class file in 2 different projects which gets compiled
into each project.
I can do something like this:

Private mobjResourceManager As ResourceManager = New ResourceManager(Reflection.Assembly.GetExecutingAs sembly.GetName.Name &
".Resources", GetType(Header).Assembly)
and that will make it work, but it seems like I shouldn't have to from other examples.
Thanks,
Chris

Nov 17 '05 #6
I tried renaming them to something different and I still got the error.
When you instantiate the ResourceManager are you using just the name of
the resource files or do you put in the AssemblyName.Resources?

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 17 '05 #7
"Chris Strobel" <st******@kubota-kma.com> wrote in message
news:#w**************@TK2MSFTNGP12.phx.gbl...
I tried renaming them to something different and I still got the error.
When you instantiate the ResourceManager are you using just the name of
the resource files or do you put in the AssemblyName.Resources?


I don't use this method.

Just try it without the ".resources" extension and see what happens.
--
John

Nov 18 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2202
by: Guoqi Zheng | last post by:
Dear sir, I have a site, http://www.vitaminstore.nl. Inside that site, I have some virtual dictionaries. For example, http://www.vitaminstore.nl/search/ or some subdomains like...
2
2630
by: flat_ross | last post by:
Hi, I am in a shop where developers are required to work off of a network share. This is so that code is backed up nightly. So I am testing running an ASP.NET Web application with a Class...
4
1634
by: Anders K. Jacobsen [DK] | last post by:
Hi I have some common UserControls i want to share between to sites (on the same mashine but on diffrent virtual paths). right now i have on solution file with aprox 10 projects. 2 of these is...
4
1965
by: SB | last post by:
Hi I'm trying to get forms-based authentication to authenticate different users for differet pages, like this: <configuration> <location path="Member" allowOverride="true"> <system.web>...
2
2670
by: §iD` | last post by:
Hi! I would like to create a virtual folder (which I want to mount) and populate managing his content by a DLL or something like that in VB.NET (2.0). How can I acomplish this? Thanks to...
8
2525
by: Nate | last post by:
I am running on Window 2003. I have a website built in ASP.NET 2.0. I need to have a Virtual Directory running an application in 1.1. I have configured each in its own Application Pool. The 1.1...
10
3356
by: TS | last post by:
i just noticed the website i created in VS 2005 is running on a different port than the default. I see that it is running on the local web server, and also that the website i created isn't in IIS....
2
1455
by: tshad | last post by:
I have set up a Virtual Directory underneath my normal Web Site in IIS 6 for 2 of our sites. One of them works file. The other one is giving me an error:...
1
2054
by: rogersmithiii | last post by:
We have a production web site - www.thesite.com - laid out as follows on IIS 6: d:\Inetpub\wwwroot\default.asp There are lots of subdirectories inside of WWWROOT including a cgi-bin directory...
0
7098
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7298
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7366
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7471
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5610
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3176
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1526
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
754
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
406
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.