Solved

.aspx runs on localhost but not on real server?

Posted on 2003-11-28
6
380 Views
Last Modified: 2010-04-16
hi all,
following problem:
I work with VisualStudio.NET. I have some code here (several *.aspx + *.aspx.cs files) which works perfect ;) on localhost.
But if I copy the files to a different directory on localhost it does not work any more.

" Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS."

Ok, so I deleted "Web.config", then I get the following error:
" Parser Error Message: Could not load type 'test1.multiLanguageEditVariable'."
in line:
"<%@ Page language="c#" Codebehind="multiLanguageEditVariable.aspx.cs" AutoEventWireup="false" Inherits="test1.multiLanguageEditVariable" %>"

But both files files exist (apsx and aspx.cs) and a apsx.resx ios beeing generated.

The problem:
I can only upload (FTP) files to the real server, I can't configure folders to become an application.

What can I do to get my files working online?

Thank you, regards
0
Comment
Question by:Smoerble
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 4

Expert Comment

by:MrGhost
ID: 9837072
Go to the IIS and check your folder (Properties) if under application name CREATE button is enabled then click it!
If not check the path!
0
 

Author Comment

by:Smoerble
ID: 9837096
As I said:
I cannot do anything like this on the server, I only have FTP access.
I already have some working *.aspx scripts there, but I created them without VisualStudio.
0
 
LVL 4

Expert Comment

by:MrGhost
ID: 9837441
where is your bin folder located? It can be just anywhere
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 4

Accepted Solution

by:
MrGhost earned 500 total points
ID: 9837473
Or maybe you just need to rebuild your app after you deleted web.config

or maybe this will help(copy/paste):

These errors can be frustrating.  Usually "Could not load type" exceptions
result from the DDL not being found, incorrect file permissions on the DLL,
or version mismatch between the assembly that needs to be loaded and the
one that was discovered.  

Is the bin directory you are using c:\inetpub\wwwroot\dotnetforms\bin?  If
so, then it wouldn't hurt to go into the MMC and verify that there is a web
application that corresponds to c:\inetpub\wwwroot\dotnetforms.  Only the
<WebAppRoot>\bin directory and the Global Assembly Cache (GAC) are searched
for assemblies.

Next, check the file permissions on the DLL to ensure that read and execute
rights have been granted to the user the request will be executing as.  An
easy way to verify that this is not permissions-related is to grant
everyone full control, OR disable anonymous authentication and authenticate
as an administrator.

Next, if the DLL is there and the permissions look correct, check for a
version mismatch.  You can see the version number of the assembly that is
trying to be loaded in the error (1.0.785.42706).  To determine the version
of the assembly in the bin directory, you can use ildasm.exe or just view
Properties->Version of the file in Windows Explorer.  These versions should
match.  You can also use ildasm to verify the name of the assembly.


If you still are getting an error after these steps, please let me know
what you found and we can go from there.  You might also want to check out
the information below:

How the Runtime Locates Assemblies
http://msdn.microsoft.com/library/en-us/cpguide/html/cpconhowruntimelocatesa
ssemblies.asp

Assembly Binding Log Viewer (Fuslogvw.exe)
http://msdn.microsoft.com/library/en-us/cptools/html/cpgrffusionlogviewerfus
0
 

Author Comment

by:Smoerble
ID: 9837529
thx for the copy paste, that helped.
the dll was in test2/bin, not in wwwroot/bin ;)

Points granted for the copyPaster ;)
0
 
LVL 4

Expert Comment

by:MrGhost
ID: 9837695
:)
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

726 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