2014-09-06 3 views
1

Я новичок в ext.net. Я создаю новый проект, и я меняю код web.config, но всегда принимаю конфигурационную ошибку. Что я должен сделать, чтобы исправить это? вот мой код web.config.Как исправить ошибки конфигурации в ext.net?

<?xml version="1.0"?> 
<configuration> 
    <configSections> 
    <section name="extnet" type="Ext.Net.GlobalConfig" requirePermission="false"/> 
</configSections> 
<extnet scriptMode="Release"/> 
<!-- See Property Options in README.txt --> 
<!-- 
    The following system.web section is only requited for running ASP.NET AJAX under Internet 
    Information Services 6.0 (or earlier). This section is not necessary for IIS 7.0 or later. 
    --> 
<system.web> 
    <httpHandlers> 
     <add path="*/ext.axd" verb="*" type="Ext.Net.ResourceHandler" validate="false"/> 
    </httpHandlers> 
    <httpModules> 
     <add name="DirectRequestModule" type="Ext.Net.DirectRequestModule, Ext.Net"/> 
    </httpModules> 
    <compilation debug="true"> 
     <assemblies> 
      <add assembly="System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> 
      <add assembly="System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> 
      <add assembly="System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> 
      <add assembly="System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> 
      <add assembly="System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> 
      <add assembly="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> 
      <add assembly="System.Xml, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> 
      <add assembly="System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> 
      <add assembly="Microsoft.CSharp, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> 
      <add assembly="System.ComponentModel.DataAnnotations, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/></assemblies></compilation></system.web> 
<!-- 
    The system.webServer section is required for running ASP.NET AJAX under Internet Information Services 7.0. 
    It is not necessary for previous version of IIS. 
--> 
<system.webServer> 
    <validation validateIntegratedModeConfiguration="false"/> 
    <modules> 
     <add name="DirectRequestModule" preCondition="managedHandler" type="Ext.Net.DirectRequestModule, Ext.Net"/> 
    </modules> 
    <handlers> 
     <add name="DirectRequestHandler" verb="*" path="*/ext.axd" preCondition="integratedMode" type="Ext.Net.ResourceHandler"/> 
    </handlers> 
</system.webServer> 

ответ

0

Добавить </ configuration> в конец файла

0

Вы можете добавить схему в Visual Studio. Я сделал схему, которую вы можете добавить вручную.

http://forums.ext.net/showthread.php?27683-XML-Extnet-Schema-to-avoid-Information-Error-in-web-config

Добавьте этот код перед тегом в DotNetConfig.xsd схеме. Я создаю элемент, основанный на файле 2.4.0 README. http://examples.ext.net/#/Getting_St...uments/README/

<?xml version="1.0" encoding="us-ascii"?> 
    <xs:element name="extnet" vs:help="configuration/extnet"> 
    <xs:complexType> 
     <xs:attribute name="ajaxViewStateMode" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Default" /> 
      <xs:enumeration value="Exclude" /> 
      <xs:enumeration value="Include" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="cleanResourceUrl" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="dateTimeZoneHandling" type="xs:string" use="optional" /> 
     <xs:attribute name="disableViewState" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="directEventUrl" type="xs:string" use="optional" /> 
     <xs:attribute name="directMethodProxy" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Default" /> 
      <xs:enumeration value="Include" /> 
      <xs:enumeration value="Ignore" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="directMethodNamespace" type="xs:string" use="optional" /> 
     <xs:attribute name="glyphFontFamily" type="xs:string" use="optional" /> 
     <xs:attribute name="gzip" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="idMode" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Client" /> 
      <xs:enumeration value="Explicit" /> 
      <xs:enumeration value="Ignore" /> 
      <xs:enumeration value="Inherit" /> 
      <xs:enumeration value="Legacy" /> 
      <xs:enumeration value="Parent" /> 
      <xs:enumeration value="Predictable" /> 
      <xs:enumeration value="Static" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="initScriptMode" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Inline" /> 
      <xs:enumeration value="Linked" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="licenseKey" type="xs:string" use="optional" /> 
     <xs:attribute name="locale" type="xs:string" use="optional" /> 
     <xs:attribute name="namespace" type="xs:string" use="optional" /> 
     <xs:attribute name="renderScripts" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Embedded" /> 
      <xs:enumeration value="File" /> 
      <xs:enumeration value="CDN" /> 
      <xs:enumeration value="None" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="renderStyles" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Embedded" /> 
      <xs:enumeration value="File" /> 
      <xs:enumeration value="CDN" /> 
      <xs:enumeration value="None" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="resourcePath" type="xs:string" use="optional" /> 
     <xs:attribute name="resourcesStrategyType" type="xs:string" use="optional" /> 
     <xs:attribute name="resetStyles" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="rethrowAjaxExceptions" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="rtl" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="scriptMode" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Release" /> 
      <xs:enumeration value="Debug" /> 
      <xs:enumeration value="Development" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="showWarningOnAjaxFailure" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="sourceFormatting" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="stateProvider" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="PostBack" /> 
      <xs:enumeration value="Cookie" /> 
      <xs:enumeration value="None" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="submitDisabled" type="small_boolean_Type" use="optional" /> 
     <xs:attribute name="theme" use="optional"> 
     <xs:simpleType> 
      <xs:restriction base="xs:string"> 
      <xs:enumeration value="Default" /> 
      <xs:enumeration value="Access" /> 
      <xs:enumeration value="Gray" /> 
      <xs:enumeration value="Neptune" /> 
      </xs:restriction> 
     </xs:simpleType> 
     </xs:attribute> 
     <xs:attribute name="themePath" type="xs:string" use="optional" /> 
     <xs:attribute name="quickTips" type="small_boolean_Type" use="optional" /> 
     <xs:anyAttribute namespace="http://schemas.microsoft.com/XML-Document-Transform" processContents="strict"/> 
    </xs:complexType> 
    </xs:element> 

Затем вы можете отлаживать, что неправильно в вашей конфигурации ext.net. Кроме того, вы можете использовать и использовать Ext.net Intellisense на web.config: D

Смежные вопросы