Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / March 2007

Tip: Looking for answers? Try searching our database.

The application's configuration files must contain 'trust' section

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Satish Babu Dasari - 11 Jan 2006 07:20 GMT
HI,

I have created Webservice project in Visual Studio 2005, by default it is
created the Service.asmx file with the code as

[WebMethod]
   public string HelloWorld() {
       return "Hello World";
   }

I tried to build this project, but it is giving compilation error
"The application's configuration files must contain 'trust' section."

Please send me the solution how to solve this problem.

Thank s in advance.

Regards
Satish
Emmanuel DURAND - 11 Jan 2006 09:33 GMT
Hi,

I (also) have created Webservice project in Visual Studio 2003, by default
it is
created the Service.asmx file with the code as

[WebMethod]
    public string HelloWorld() {
        return "Hello World";
    }

I can build this project, I can see first and second pages of asp result
(meaning list of methods and method test button), but when
choose HelloWorld test button I get an HTTP 500 error (internal server
error).
When I refresh (F5) the HTML error page, I get more information you can read
below.

I use .NET 1.1.4, IIS5 and don't understand what happends.

Thanks in advance.

Regards

Stack
[InvalidOperationException: Format de demande non reconnu.] (unknown demand
format)

System.Web.Services.Protocols.WebServiceHandlerFactory.CoreGetHandler(Type
type, HttpContext context, HttpRequest request, HttpResponse response)

System.Web.Services.Protocols.WebServiceHandlerFactory.GetHandler(HttpContex
t context, String verb, String url, String filePath)
  System.Web.HttpApplication.MapHttpHandler(HttpContext context, String
requestType, String path, String pathTranslated, Boolean useAppConfig) +699

System.Web.MapHandlerExecutionStep.System.Web.HttpApplication+IExecutionStep
.Execute() +95
  System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean&
completedSynchronously) +173
Chesnut - 07 Mar 2007 18:18 GMT
> HI,
>
[quoted text clipped - 15 lines]
> Regards
> Satish

Make sure your machine.config file is not corrupt.  Open \Microsoft.NET\Framework\v2.0.50727\CONFIG\machine.config and make sure there is only one closing </configuration> tag.

BizTalk Utilities - Frustration free BizTalk Adapters
http://www.topxml.com/biztalkutilities

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.