none
Auto-populate drop down list (Choice) field in custom List Form using value from SQL database

    Question

  • Hi,

    My client is running the following configuration:

    - WSS 3.0 running on Windows Server 2003
    - Forms Based Authentication (SQL Server 2005) using the default aspnetdb Membership database
    - Custom table in 'aspnetdb' to store additional User data such as Company, Department, etc.

    We have a Custom List, and have customized the NewForm.aspx, DispForm.aspx and EditForm.aspx List Forms.

    This Custom List contains a Company field among other fields. It is a 'Choice' type field.

    The User's 'Company' info is stored in a Custom SQL table that exists in the 'aspnetdb' database.

    Requirement:
    When a User creates (using the custom 'NewForm.aspx') a new Item in the Custom List, we want to to be able to retrieve the Company information from the SQL table in aspnetdb, and auto-populate the 'Choice' field in NewForm.aspx.

    I tried using the 'ItemAdding' List Item Event Receiver but found out that this Event gets 'triggered' only when the 'OK' button is clicked on the NewForm.aspx. What we would like to have is a 'OnLoad' event that retrieves the 'Company' info from the SQL table and populates the 'Choice' field when the NewForm.aspx Form is loaded.

    I did check out the Query String parameter approaches in this Forum, but that would mean that I would need to retrieve the 'Company' value (say, Karft) from the datbase first, and then pass it as a QS parameter like this
    '\NewForm.aspx?Company=Kraft'

    And this value would change based on the Users as they belong to different Companies.

    How can I auto-populate drop down list (Choice) field in custom List Form using value from SQL database?

    Thank you very much.

    Cheers!
    Kiran









    Saturday, March 06, 2010 7:50 PM

Answers

  • Hi Kiran,

    As you mentioned “What we would like to have is a 'OnLoad' event that retrieves the 'Company' info from the SQL table and populates the 'Choice' field when the NewForm.aspx Form is loaded.”,You should do the things before you deliver the page to the client side.
    In other words, you should populate the drop down list when you create the “NewForm.aspx” or “EditForm.aspx” page.

    Note:

    In the 'Load' event handler function of the page (NewForm.aspx or EditForm.aspx), you can get the ‘company’ value from the database, and then populate the drop down list in the ‘company’ list field.

    Let me know if you have further questions!

    Hope it is helpful!

    • Edited by Seven M Wednesday, March 10, 2010 1:43 AM
    • Marked as answer by Seven M Thursday, March 11, 2010 2:18 AM
    Monday, March 08, 2010 3:24 AM
  • If you want to add code on newform.aspx then you can add code before this line

    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">

    ---- Code to be add
    <
    script runat="server">
    protected void Page_Load(object sender, EventArgs e)
        {
            if (this.IsPostBack == false)
            {
               //Your code...
            }
    }
    </script>


    Do not forgot to update parser path in web config

    <PageParserPath VirtualPath="/*" CompilationMode="Always" AllowServerSideScript="true" IncludeSubFolders="true" />

    Let me know this works for you or not


    Ashish Kanoongo, MCP, MCSD, MCTS
    • Marked as answer by Seven M Thursday, March 11, 2010 2:18 AM
    Monday, March 08, 2010 4:36 AM
  • Hi Ashish,

    I got this working using an alternate approach.

    I created a SmartPart Web Part (http://www.codeplex.com/smartpart) which runs on 'Page_Load' event and retrieves the 'Company' value for the user from the database and stores it in a text field. I then added the SmartPart Web Part on top my custom NewForm.aspx page, and then hid it.

    I then added JavaScript code to retrieve the Company value from the text field in the 'hidden' SmartPart Web Part and set it in the 'Company' field in the custom NewForm.aspx page.

    Best regards,

    Kiran

    • Marked as answer by Seven M Thursday, March 11, 2010 2:17 AM
    Tuesday, March 09, 2010 5:48 PM

All replies

  • Hi Kiran,

    As you mentioned “What we would like to have is a 'OnLoad' event that retrieves the 'Company' info from the SQL table and populates the 'Choice' field when the NewForm.aspx Form is loaded.”,You should do the things before you deliver the page to the client side.
    In other words, you should populate the drop down list when you create the “NewForm.aspx” or “EditForm.aspx” page.

    Note:

    In the 'Load' event handler function of the page (NewForm.aspx or EditForm.aspx), you can get the ‘company’ value from the database, and then populate the drop down list in the ‘company’ list field.

    Let me know if you have further questions!

    Hope it is helpful!

    • Edited by Seven M Wednesday, March 10, 2010 1:43 AM
    • Marked as answer by Seven M Thursday, March 11, 2010 2:18 AM
    Monday, March 08, 2010 3:24 AM
  • Thanks for your response Seven.

    Where would I add the 'OnLoad' event handler function? Can you please provide a sample code snippet or point me to an online resource?

    Thanks. Look forward to your response.

    Kiran

    Monday, March 08, 2010 4:16 AM
  • If you want to add code on newform.aspx then you can add code before this line

    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">

    ---- Code to be add
    <
    script runat="server">
    protected void Page_Load(object sender, EventArgs e)
        {
            if (this.IsPostBack == false)
            {
               //Your code...
            }
    }
    </script>


    Do not forgot to update parser path in web config

    <PageParserPath VirtualPath="/*" CompilationMode="Always" AllowServerSideScript="true" IncludeSubFolders="true" />

    Let me know this works for you or not


    Ashish Kanoongo, MCP, MCSD, MCTS
    • Marked as answer by Seven M Thursday, March 11, 2010 2:18 AM
    Monday, March 08, 2010 4:36 AM
  • Hi Ashish,

    I added the code per your suggestion, above the <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server"> line.
    I added 3 Import statements for System.Configuration, System.Data, System.Data.SqlClient Namespaces.
    I also had to specify type="text/C#" in the opening <script> tag.


    Here is the code that I added to 'NewForm.aspx'

    <%@ Page language="C#" MasterPageFile="~masterurl/default.master"    Inherits="Microsoft.SharePoint.WebPartPages.WebPartPage,Microsoft.SharePoint,Version=12.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" meta:progid="SharePoint.WebPartPage.Document" title="NEW Download Manager" meta:webpartpageexpansion="full" %>
    <%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Import Namespace="Microsoft.SharePoint" %> <%@ Import Namespace="System.Configuration" %> <%@ Import Namespace="System.Data" %> <%@ Import Namespace="System.Data.SqlClient" %>  <%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
    
    <script runat="server" type="text/C#">
    protected void Page_Load(object sender, EventArgs e)
        {
        
        try
          {
            if (this.IsPostBack == false)
            {
    			SqlConnection objSqlConn;
    
                string dbConnString = ConfigurationManager.ConnectionStrings["aspnetdbConnectionString"].ConnectionString;
    
                objSqlConn = new SqlConnection(dbConnString);
    
    
                    //Get current logged in user's id
                    string strCurrentUserID = SPContext.Current.Web.CurrentUser.Email.ToString();
    
                    SqlCommand objSqlCmd = new SqlCommand();
                    objSqlConn.Open();
                    objSqlCmd.Connection = objSqlConn;
                    objSqlCmd.CommandType = System.Data.CommandType.StoredProcedure;
                    objSqlCmd.CommandText = "aspnet_GetUserCompany";
                    objSqlCmd.Parameters.Add("@Email", SqlDbType.NVarChar).Value = strCurrentUserID;
                    string strUserCompany = (string)objSqlCmd.ExecuteScalar();                
             }
           }//closing try
    
        catch (Exception ex)
        {
            throw ex;
        }
    
        finally
        {
            if (objSqlConn.State == ConnectionState.Open)
              {
                  objSqlConn.Close();
              }
            objSqlConn.Dispose();
        }
    			
            
    }
    </script>
    
    
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">
    
    Here is the 'PageParserPath' line that I added to the application's web.config file.

    <SharePoint>
        <SafeMode MaxControls="200" CallStack="true" DirectFileDependencies="10" TotalFileDependencies="50" AllowPageLevelTrace="false">
          <PageParserPaths>
             <PageParserPath VirtualPath="/*" CompilationMode="Always" AllowServerSideScript="true" IncludeSubFolders="true" /> 
          </PageParserPaths>
        </SafeMode>
    
    <! -- other config lines here -->
    </SharePoint>
    I get the following related error, when I try to browse to the SharePoint site. It appears to be occurring in the MasterPage code.

     

    Server Error in '/' Application.

    Compilation Error

    Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

    Compiler Error Message: CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.EncodedLiteral' to 'System.Web.UI.IAttributeAccessor'

    Source Error:

    Line 45: 			  <span id="TurnOffAccessibility" style="display:none">
    Line 46: 				<a href="#" class="ms-acclink" onclick="SetIsAccessibilityFeatureEnabled(false);UpdateAccessibilityUI();return false;">
    Line 47: 				<SharePoint:EncodedLiteral runat="server" text="<%$Resources:wss,master_turnoffaccessibility%>" EncodeMethod="HtmlEncode" __designer:Preview="Turn off more accessible mode" __designer:Values="&lt;P N='Text' Bound='True' T='Resources:wss,master_turnoffaccessibility' /&gt;&lt;P N='ID' T='ctl09' /&gt;&lt;P N='Page' ID='1' /&gt;&lt;P N='TemplateControl' ID='2' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;"/></a>
    Line 48: 			  </span>
    Line 49: 			  <asp:ContentPlaceHolder id="PlaceHolderGlobalNavigationSiteMap" runat="server">

    Source File: /_catalogs/masterpage/default2.master    Line: 47


    Show Detailed Compiler Output:

    c:\windows\system32\inetsrv> "C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\csc.exe" /t:library /utf8output /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_Web_designmodeconsole.ascx.5f1d2a77.hkp8wufh.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.IdentityModel\3.0.0.0__b77a5c561934e089\System.IdentityModel.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_Web_welcome.ascx.5f1d2a77.xdbyfypw.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\1.0.61025.0__31bf3856ad364e35\System.Web.Extensions.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_GlobalResources.jxm4iogu.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.ServiceModel\3.0.0.0__b77a5c561934e089\System.ServiceModel.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\90e4a851\246c2541_4ba0ca01\Bamboo.HelperWebParts.ChangePassword.DLL" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\1adc8cc9\ccca4943_4ba0ca01\Bamboo.UserDirectory.DLL" /R:"C:\WINDOWS\assembly\GAC_64\System.EnterpriseServices\2.0.0.0__b03f5f7f11d50a3a\System.EnterpriseServices.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Mobile\2.0.0.0__b03f5f7f11d50a3a\System.Web.Mobile.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\8855b2c8\a4e5a242_4ba0ca01\Bamboo.UserAccount.Setup.WebPart.DLL" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\mscorlib.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\09c7041f\54b2ed41_4ba0ca01\Bamboo.PasswordExpirationReminder.DLL" /R:"C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SharePoint\12.0.0.0__71e9bce111e9429c\Microsoft.SharePoint.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Web.Services\2.0.0.0__b03f5f7f11d50a3a\System.Web.Services.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Drawing\2.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_global.asax.hrn8itwb.dll" /R:"C:\WINDOWS\assembly\GAC_64\System.Web\2.0.0.0__b03f5f7f11d50a3a\System.Web.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Xml\2.0.0.0__b77a5c561934e089\System.Xml.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Configuration\2.0.0.0__b03f5f7f11d50a3a\System.Configuration.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\6a373f00\84ca8441_4ba0ca01\Bamboo.ListRollup.WebPart.DLL" /R:"C:\WINDOWS\assembly\GAC_64\System.Data\2.0.0.0__b77a5c561934e089\System.Data.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.WorkflowServices\3.5.0.0__31bf3856ad364e35\System.WorkflowServices.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\d42e3d4f\e8c8de3f_4ba0ca01\Bamboo.AdvancedSearch.DLL" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.Runtime.Serialization\3.0.0.0__b77a5c561934e089\System.Runtime.Serialization.dll" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\83c9d092\54b2ed41_4ba0ca01\Bamboo.PasswordExpirationService.DLL" /R:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\assembly\dl3\bb60a343\44874342_4ba0ca01\Bamboo.PasswordReset.DLL" /R:"C:\WINDOWS\assembly\GAC_MSIL\System.ServiceModel.Web\3.5.0.0__31bf3856ad364e35\System.ServiceModel.Web.dll" /out:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_Web_5bafa904-429b-4d8a-8068-08fc0dbf043e_-1053194202.loufsd8s.dll" /debug- /optimize+ /win32res:"C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\bi9cwjko.res" /w:4 /nowarn:1659;1699;1701  "C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_Web_5bafa904-429b-4d8a-8068-08fc0dbf043e_-1053194202.loufsd8s.0.cs" "C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\root\e14b3ff3\df4f6e9e\App_Web_5bafa904-429b-4d8a-8068-08fc0dbf043e_-1053194202.loufsd8s.1.cs"
    
    
    Microsoft (R) Visual C# 2005 Compiler version 8.00.50727.3053
    for Microsoft (R) Windows (R) 2005 Framework version 2.0.50727
    Copyright (C) Microsoft Corporation 2001-2005. All rights reserved.
    
    http://server/_catalogs/masterpage/default2.master(47,18): error CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.EncodedLiteral' to 'System.Web.UI.IAttributeAccessor'
    http://server/_catalogs/masterpage/default2.master(47,18): error CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.EncodedLiteral' to 'System.Web.UI.IAttributeAccessor'
    http://server/_catalogs/masterpage/default2.master(88,18): error CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.DelegateControl' to 'System.Web.UI.IAttributeAccessor'
    http://server/_catalogs/masterpage/default2.master(88,18): error CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.DelegateControl' to 'System.Web.UI.IAttributeAccessor'
    http://server/_catalogs/masterpage/default2.master(90,18): error CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.DelegateControl' to 'System.Web.UI.IAttributeAccessor'
    http://server/_catalogs/masterpage/default2.master(90,18): error CS0030: Cannot convert type 'Microsoft.SharePoint.WebControls.DelegateControl' to 'System.Web.UI.IAttributeAccessor'


    The SharePoint site loads fine, if I comment out the 'PageParserPath' line from the 'web.config' file. But when I attempt to create a new Item using NewForm.aspx, I get this error:

     

    Server Error in '/' Application.

    Parser Error

    Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

    Parser Error Message: Code blocks are not allowed in this file.

    Source Error:

    Line 46:         
    Line 47: }
    Line 48: </script>
    Line 49: 
    Line 50: 

    Source File: /Lists/NEW Download Manager/CustomNewForm.aspx    Line: 48


    Version Information: Microsoft .NET Framework Version:2.0.50727.3603; ASP.NET Version:2.0.50727.3082


    What am I missing? Please let me know. Thank you very much for your help and time.

    Kiran
    Monday, March 08, 2010 6:25 AM
  • Hi Kiran,

     

    For the error, please debug the new code using visual studio debug function.


    Here are some useful resources related visual studio debug function:
    http://msdn.microsoft.com/en-us/library/system.diagnostics.debug.aspx
    http://support.microsoft.com/kb/815788

     

     

    Let me know if you have further questions!

     

    Hope it is helpful!

    Monday, March 08, 2010 9:58 AM
  • Can you please post your code of newform.aspx
    Ashish Kanoongo, MCP, MCSD, MCTS
    Monday, March 08, 2010 2:40 PM
  • Ashish,

    Here is code in 'NewForm.aspx':

    <%@ Page language="C#" MasterPageFile="~masterurl/default.master"    Inherits="Microsoft.SharePoint.WebPartPages.WebPartPage,Microsoft.SharePoint,Version=12.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" meta:progid="SharePoint.WebPartPage.Document" title="NEW Download Manager" %>
    <%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Import Namespace="Microsoft.SharePoint" %> <%@ Import Namespace="System.Configuration" %> <%@ Import Namespace="System.Data" %> <%@ Import Namespace="System.Data.SqlClient" %>  <%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
    
    <script runat="server" type="text/C#">
    protected void Page Load(object sender, EventArgs e)
        {
        
        try
          {
            if (this.IsPostBack == false)
            {
    			SqlConnection objSqlConn;
    
                string dbConnString = ConfigurationManager.ConnectionStrings["aspnetdbConnectionString"].ConnectionString;
    
                objSqlConn = new SqlConnection(dbConnString);
    
    
                    //Get current logged in user's id
                    string strCurrentUserID = SPContext.Current.Web.CurrentUser.Email.ToString();
    
                    SqlCommand objSqlCmd = new SqlCommand();
                    objSqlConn.Open();
                    objSqlCmd.Connection = objSqlConn;
                    objSqlCmd.CommandType = System.Data.CommandType.StoredProcedure;
                    objSqlCmd.CommandText = "aspnet_NTTD_GetUserCompany";
                    objSqlCmd.Parameters.Add("@Email", SqlDbType.NVarChar).Value = strCurrentUserID;
                    string strUserCompany = (string)objSqlCmd.ExecuteScalar();                
             }
           }//closing try
    
        catch (Exception ex)
        {
            throw ex;
        }
    
        finally
        {
            if (objSqlConn.State == ConnectionState.Open)
              {
                  objSqlConn.Close();
              }
            objSqlConn.Dispose();
        }
    			
            
    }
    </script>
    
    
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">
    	<SharePoint:ListFormPageTitle runat="server"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitleInTitleArea" runat="server">
    	<SharePoint:ListProperty Property="LinkTitle" runat="server" id="ID_LinkTitle"/>: 
    	<SharePoint:ListItemProperty id="ID_ItemProperty" MaxLength=40 runat="server"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageImage" runat="server">
    	<IMG SRC="../../_layouts/images/blank.gif" width=1 height=1 alt="">
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderLeftNavBar" runat="server"/>
    <asp:Content ContentPlaceHolderId="PlaceHolderMain" runat="server">
    <table cellpadding=0 cellspacing=0 id="onetIDListForm">
     <tr>
      <td>
     <WebPartPages:WebPartZone runat="server" FrameType="None" ID="Main" Title="loc:Main"><ZoneTemplate>
    <WebPartPages:ListFormWebPart runat="server" __MarkupType="xmlmarkup" WebPart="true" __WebPartId="{B33C09BC-60CF-4315-9630-622B2C221E86}" >
    <WebPart xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.microsoft.com/WebPart/v2">
      <Title>NEW Download Manager</Title>
      <FrameType>None</FrameType>
      <Description />
      <IsIncluded>false</IsIncluded>
      <PartOrder>1</PartOrder>
      <FrameState>Normal</FrameState>
      <Height />
      <Width />
      <AllowRemove>true</AllowRemove>
      <AllowZoneChange>true</AllowZoneChange>
      <AllowMinimize>true</AllowMinimize>
      <AllowConnect>true</AllowConnect>
      <AllowEdit>true</AllowEdit>
      <AllowHide>true</AllowHide>
      <IsVisible>false</IsVisible>
      <DetailLink />
      <HelpLink />
      <HelpMode>Modeless</HelpMode>
      <Dir>Default</Dir>
      <PartImageSmall />
      <MissingAssembly>Cannot import this Web Part.</MissingAssembly>
      <PartImageLarge />
      <IsIncludedFilter />
      <ExportControlledProperties>true</ExportControlledProperties>
      <ConnectionID>00000000-0000-0000-0000-000000000000</ConnectionID>
      <ID>g_8f787152_a734_424c_a367_5f3715c85132</ID>
      <ListName xmlns="http://schemas.microsoft.com/WebPart/v2/ListForm">{52A54655-6880-4B8F-80EF-ABA2BDDF8D2A}</ListName>
      <ListItemId xmlns="http://schemas.microsoft.com/WebPart/v2/ListForm">0</ListItemId>
      <ControlMode xmlns="http://schemas.microsoft.com/WebPart/v2/ListForm">New</ControlMode>
      <TemplateName xmlns="http://schemas.microsoft.com/WebPart/v2/ListForm">ListForm</TemplateName>
      <FormType xmlns="http://schemas.microsoft.com/WebPart/v2/ListForm">8</FormType>
      <ViewFlag xmlns="http://schemas.microsoft.com/WebPart/v2/ListForm">1048576</ViewFlag>
    </WebPart>
    </WebPartPages:ListFormWebPart>
    </ZoneTemplate></WebPartPages:WebPartZone>
     <br>
    	<WebPartPages:DataFormWebPart runat="server" IsIncluded="True" FrameType="None" NoDefaultStyle="TRUE" ViewFlag="0" Title="NEW Download Manager (1)" __markuptype="vsattributemarkup" __WebPartId="{CC77B546-8896-40A0-9394-498A4C81E79E}" id="g_2547fbcf_0287_4842_b359_935d58185047" __AllowXSLTEditing="true" WebPart="true" Height="" Width="">
    	<DataSources>
    		<SharePoint:SPDataSource runat="server" DataSourceMode="ListItem" UseInternalName="true" selectcommand="&lt;View&gt;&lt;Query&gt;&lt;Where&gt;&lt;Eq&gt;&lt;FieldRef Name=&quot;ContentType&quot;/&gt;&lt;Value Type=&quot;Text&quot;&gt;Item&lt;/Value&gt;&lt;/Eq&gt;&lt;/Where&gt;&lt;/Query&gt;&lt;/View&gt;" id="NEW_x0020_Download_x0020_Manager1"><SelectParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{52A54655-6880-4B8F-80EF-ABA2BDDF8D2A}"/></SelectParameters><DeleteParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{52A54655-6880-4B8F-80EF-ABA2BDDF8D2A}"/></DeleteParameters><InsertParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{52A54655-6880-4B8F-80EF-ABA2BDDF8D2A}"/></InsertParameters><UpdateParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{52A54655-6880-4B8F-80EF-ABA2BDDF8D2A}"/></UpdateParameters></SharePoint:SPDataSource>
    	</DataSources>
    	<ParameterBindings>
    	 <ParameterBinding Name="ListItemId" Location="QueryString(ID)" DefaultValue="0"/>
    	 <ParameterBinding Name="ListID" Location="None" DefaultValue="{52A54655-6880-4B8F-80EF-ABA2BDDF8D2A}"/>
    	 <ParameterBinding Name="dvt_apos" Location="Postback;Connection"/>
    	 <ParameterBinding Name="UserID" Location="CAMLVariable" DefaultValue="CurrentUserName"/>
    	 <ParameterBinding Name="Today" Location="CAMLVariable" DefaultValue="CurrentDate"/>
     </ParameterBindings>
    	<datafields>@Security_x0020_Level,Security Level;@Select_x0020_Users_x0020_or_x002,Select Users or Groups;@Title,Title;@Description,Description;@Company,Company;@ID,ID;@ContentType,Content Type;@Modified,Modified;@Created,Created;@Author,Created By;@Editor,Modified By;@_UIVersionString,Version;@Attachments,Attachments;@File_x0020_Type,File Type;@FileLeafRef,Name (for use in forms);@FileDirRef,Path;@FSObjType,Item Type;@_HasCopyDestinations,Has Copy Destinations;@_CopySource,Copy Source;@ContentTypeId,Content Type ID;@_ModerationStatus,Approval Status;@_UIVersion,UI Version;@Created_x0020_Date,Created;@FileRef,URL Path;</datafields>
    	<XSL>
    <xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" version="1.0" exclude-result-prefixes="xsl msxsl ddwrt" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime" xmlns:asp="http://schemas.microsoft.com/ASPNET/20" xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:SharePoint="Microsoft.SharePoint.WebControls" xmlns:ddwrt2="urn:frontpage:internal">
    	<xsl:output method="html" indent="no"/>
    	<xsl:decimal-format NaN=""/>
    	<xsl:param name="dvt_apos">'</xsl:param>
    	<xsl:variable name="dvt_1_automode">0</xsl:variable>
    	<xsl:template match="/">
    		<xsl:call-template name="dvt_1"/>
    	</xsl:template>
    	<xsl:template name="dvt_1">
    		<xsl:variable name="dvt_StyleName">ListForm</xsl:variable>
    		<xsl:variable name="Rows" select="/dsQueryResponse/Rows/Row"/>
    		<div>
    			<span id="part1">
    				<table border="0" width="100%">
    					<xsl:call-template name="dvt_1.body">
    						<xsl:with-param name="Rows" select="$Rows"/>
    					</xsl:call-template>
    				</table>
    			</span>
    			<SharePoint:AttachmentUpload runat="server" ControlMode="New"/>
    			<SharePoint:ItemHiddenVersion runat="server" ControlMode="New"/>
    		</div>
    	</xsl:template>
    	<xsl:template name="dvt_1.body">
    		<xsl:param name="Rows"/>
    		<tr>
    			<td class="ms-toolbar" nowrap="">
    				<table>
    					<tr>
    						<td width="99%" class="ms-toolbar" nowrap=""><IMG SRC="/_layouts/images/blank.gif" width="1" height="18"/></td>
    						<td class="ms-toolbar" nowrap="">
    							<SharePoint:SaveButton runat="server" ControlMode="New" id="savebutton1"/>
    						</td>
    						<td class="ms-separator"> </td>
    						<td class="ms-toolbar" nowrap="" align="right">
    							<SharePoint:GoBackButton runat="server" ControlMode="New" id="gobackbutton1"/>
    						</td>
    					</tr>
    				</table>
    			</td>
    		</tr>
    		<tr>
    			<td class="ms-toolbar" nowrap="">
    				<SharePoint:FormToolBar runat="server" ControlMode="New"/>
    			</td>
    		</tr>
    		<xsl:call-template name="dvt_1.rowedit">
    		<xsl:with-param name="Pos" select="concat('_', position())" />
    		</xsl:call-template>
    		
    		<tr>
    			<td class="ms-toolbar" nowrap="">
    				<table>
    					<tr>
    						<td width="99%" class="ms-toolbar" nowrap=""><IMG SRC="/_layouts/images/blank.gif" width="1" height="18"/></td>
    						<td class="ms-toolbar" nowrap="">
    							<SharePoint:SaveButton runat="server" ControlMode="New" id="savebutton2"/>
    						</td>
    						<td class="ms-separator"> </td>
    						<td class="ms-toolbar" nowrap="" align="right">
    							<SharePoint:GoBackButton runat="server" ControlMode="New" id="gobackbutton2"/>
    						</td>
    					</tr>
    				</table>
    			</td>
    		</tr>
    	</xsl:template>
    	<xsl:template name="dvt_1.rowedit">
    		<xsl:param name="Pos" />
    		<tr>
    			<td>
    				<table border="0" cellspacing="0" width="100%">
    					<tr>
    						<td width="190px" valign="top" class="ms-formlabel">
    							<H3 class="ms-standardheader">
    								<nobr>Security Level</nobr>
    							</H3>
    						</td>
    						<td width="400px" valign="top" class="ms-formbody">
    							<SharePoint:FormField runat="server" id="ff1{$Pos}" ControlMode="New" FieldName="Security_x0020_Level" __designer:bind="{ddwrt:DataBind('i',concat('ff1',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Security_x0020_Level')}"/>
    							<SharePoint:FieldDescription runat="server" id="ff1description{$Pos}" FieldName="Security_x0020_Level" ControlMode="New"/>
    						</td>
    					</tr>
    					<tr>
    						<td width="190px" valign="top" class="ms-formlabel">
    							<H3 class="ms-standardheader">
    								<nobr>Select Users or Groups</nobr>
    							</H3>
    						</td>
    						<td width="400px" valign="top" class="ms-formbody">
    							<SharePoint:FormField runat="server" id="ff2{$Pos}" ControlMode="New" FieldName="Select_x0020_Users_x0020_or_x002" __designer:bind="{ddwrt:DataBind('i',concat('ff2',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Select_x0020_Users_x0020_or_x002')}" InputFieldLabel=""/>
    							<SharePoint:FieldDescription runat="server" id="ff2description{$Pos}" FieldName="Select_x0020_Users_x0020_or_x002" ControlMode="New"/>
    						</td>
    					</tr>
    					<tr>
    						<td width="190px" valign="top" class="ms-formlabel">
    							<H3 class="ms-standardheader">
    								<nobr>Title<span class="ms-formvalidation"> *</span>
    								</nobr>
    							</H3>
    						</td>
    						<td width="400px" valign="top" class="ms-formbody">
    							<SharePoint:FormField runat="server" id="ff3{$Pos}" ControlMode="New" FieldName="Title" __designer:bind="{ddwrt:DataBind('i',concat('ff3',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Title')}"/>
    							<SharePoint:FieldDescription runat="server" id="ff3description{$Pos}" FieldName="Title" ControlMode="New"/>
    						</td>
    					</tr>
    					<tr>
    						<td width="190px" valign="top" class="ms-formlabel">
    							<H3 class="ms-standardheader">
    								<nobr>Company<span class="ms-formvalidation"> *</span>
    								</nobr>
    							</H3>
    						</td>
    						<td width="400px" valign="top" class="ms-formbody">
    							<SharePoint:FormField runat="server" id="ff4{$Pos}" ControlMode="New" FieldName="Company" __designer:bind="{ddwrt:DataBind('i',concat('ff4',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Company')}"/>
    							<SharePoint:FieldDescription runat="server" id="ff4description{$Pos}" FieldName="Company" ControlMode="New"/>
    						</td>
    					</tr>
    					<tr>
    						<td width="190px" valign="top" class="ms-formlabel">
    							<H3 class="ms-standardheader">
    								<nobr>Description</nobr>
    							</H3>
    						</td>
    						<td width="400px" valign="top" class="ms-formbody">
    							<SharePoint:FormField runat="server" id="ff5{$Pos}" ControlMode="New" FieldName="Description" __designer:bind="{ddwrt:DataBind('i',concat('ff5',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Description')}"/>
    							<SharePoint:FieldDescription runat="server" id="ff5description{$Pos}" FieldName="Description" ControlMode="New"/>
    						</td>
    					</tr>
    					<tr id="idAttachmentsRow">
    						<td nowrap="true" valign="top" class="ms-formlabel" width="20%">
    							<SharePoint:FieldLabel ControlMode="New" FieldName="Attachments" runat="server"/>
    						</td>
    						<td valign="top" class="ms-formbody" width="80%">
    							<SharePoint:FormField runat="server" id="AttachmentsField" ControlMode="New" FieldName="Attachments" __designer:bind="{ddwrt:DataBind('i','AttachmentsField','Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Attachments')}"/>
    							<script>
              var elm = document.getElementById(&quot;idAttachmentsTable&quot;);
              if (elm == null || elm.rows.length == 0)
              document.getElementById(&quot;idAttachmentsRow&quot;).style.display=&apos;none&apos;;
            </script> </td>
    					</tr>
    					<xsl:if test="$dvt_1_automode = '1'" ddwrt:cf_ignore="1">
    						<tr>
    							<td colspan="99" class="ms-vb">
    								<span ddwrt:amkeyfield="ID" ddwrt:amkeyvalue="ddwrt:EscapeDelims(string(@ID))" ddwrt:ammode="view"></span>
    							</td>
    						</tr>
    					</xsl:if>
    				</table>
    			</td>
    		</tr>
    		
    	</xsl:template>
    </xsl:stylesheet>	</XSL>
    </WebPartPages:DataFormWebPart>
    <WebPartPages:ContentEditorWebPart runat="server" __MarkupType="xmlmarkup" WebPart="true" __WebPartId="{3FD5466E-D85D-4CC5-A11D-31EB21E757DE}">
    <WebPart xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.microsoft.com/WebPart/v2">
      <Title>ContentEditorWebPart</Title>
      <FrameType>Default</FrameType>
      <Description>Use for formatted text, tables, and images.</Description>
      <IsIncluded>true</IsIncluded>
      <PartOrder>1</PartOrder>
      <FrameState>Normal</FrameState>
      <Height />
      <Width />
      <AllowRemove>true</AllowRemove>
      <AllowZoneChange>true</AllowZoneChange>
      <AllowMinimize>true</AllowMinimize>
      <AllowConnect>true</AllowConnect>
      <AllowEdit>true</AllowEdit>
      <AllowHide>true</AllowHide>
      <IsVisible>false</IsVisible>
      <DetailLink />
      <HelpLink />
      <HelpMode>Modeless</HelpMode>
      <Dir>Default</Dir>
      <PartImageSmall />
      <MissingAssembly>Cannot import this Web Part.</MissingAssembly>
      <PartImageLarge />
      <IsIncludedFilter />
      <ExportControlledProperties>true</ExportControlledProperties>
      <ConnectionID>00000000-0000-0000-0000-000000000000</ConnectionID>
      <ID>g_3fd5466e_d85d_4cc5_a11d_31eb21e757de</ID>
      <ContentLink xmlns="http://schemas.microsoft.com/WebPart/v2/ContentEditor" />
      <Content xmlns="http://schemas.microsoft.com/WebPart/v2/ContentEditor"><![CDATA[<script type="text/javascript">
    
    _spBodyOnLoadFunctionNames.push("getSecurityLevelValue");
    
    function hidePeoplePicker() {
    //alert("HIDE");
    var control = getTagFromIdentifierAndTitle('textarea','UserField_downlevelTextBox','People Picker');
    
    control.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.style.display="none";
    
    }
    
    function showPeoplePicker() {
    //alert("SHOW");
    var control = getTagFromIdentifierAndTitle('textarea','UserField_downlevelTextBox','People Picker');
    
    control.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.style.display="";
    
    }
    
    function getTagFromIdentifierAndTitle(tagName, identifier, title)
    {
    
    //alert("tagName = " + tagName);
    
    var len = identifier.length;
    
    //alert("Len = " + len);
    
    var tags = document.getElementsByTagName(tagName);
    //alert("tags length = " + tags.length);
    
    for (var i=0; i < tags.length; i++)
    
    {
    
    var tempString = tags[i].id;
    //alert("tempString = " + tempString);
    if (tags[i].title == title && (identifier == "" || tempString.indexOf(identifier) == tempString.length - len))
    
    {
    
    return tags[i];
    
    }
    
    }
    return null;
    
    }
    
    function getField(fieldType,fieldTitle) {   
        var docTags = document.getElementsByTagName(fieldType);
        //alert("Length = " + docTags.length);   
        for (var i=0; i < docTags.length; i++) {   
            if (docTags[i].title == fieldTitle) {   
               //alert("Value in getField = " + docTags[i].value);
               return docTags[i];   
            }   
        }   
    } 
    
    function getSecurityLevelValue() { 
    //alert("In getSecurityLevelValue");  
    selectedId = getField('select','Security Level').options[getField('select','Security Level').selectedIndex].value;   
    //alert("Value in hide =" + selectedId);
       if(selectedId != 'Specific User')
       {
          //alert("NOT Specific User");
          hidePeoplePicker();
       }
       else
       { 
         //alert("Specific User");  
         showPeoplePicker();
       }
    }
    
    
    getField('select','Security Level').onchange = function() {getSecurityLevelValue()};   
    
    </script>]]></Content>
      <PartStorage xmlns="http://schemas.microsoft.com/WebPart/v2/ContentEditor" />
    </WebPart>
    </WebPartPages:ContentEditorWebPart>
     <IMG SRC="../../_layouts/images/blank.gif" width=590 height=1 alt="">
      </td>
     </tr>
    </table>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleLeftBorder" runat="server">
    <table cellpadding=0 height=100% width=100% cellspacing=0>
     <tr><td class="ms-areaseparatorleft">
    				<IMG SRC="../../_layouts/images/blank.gif" width=1 height=1 alt=""></td></tr>
    </table>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleAreaClass" runat="server">
    <script id="onetidPageTitleAreaFrameScript">
    	document.getElementById("onetidPageTitleAreaFrame").className="ms-areaseparator";
    </script>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyAreaClass" runat="server">
    <style type="text/css">
    .ms-bodyareaframe {
    	padding: 8px;
    	border: none;
    }
    </style>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyLeftBorder" runat="server">
    <div class='ms-areaseparatorleft'>
    				<IMG SRC="../../_layouts/images/blank.gif" width=8 height=100% alt=""></div>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleRightMargin" runat="server">
    <div class='ms-areaseparatorright'>
    				<IMG SRC="../../_layouts/images/blank.gif" width=8 height=100% alt=""></div>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyRightMargin" runat="server">
    <div class='ms-areaseparatorright'>
    				<IMG SRC="../../_layouts/images/blank.gif" width=8 height=100% alt=""></div>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleAreaSeparator" runat="server"/>
    
    Monday, March 08, 2010 3:06 PM
  • I checked whole code and did not find any problem, unfortunately not able to test because I need to create list for this.

    I will create a a list as per your page and test it and let you know


    Ashish Kanoongo, MCP, MCSD, MCTS
    Monday, March 08, 2010 4:08 PM
  • Ashish - Thank you very much for continuing to help me out with this. I greatly appreciate it.

    Here are some details related to the Custom List.

    It has the following 5 Columns. I have also included the Column Types. File Attachments are allowed in this List.

    1. Security Level (Choice). The values are Public, Specific User, Company Internal Use

    2. Select Users or Groups (Person or Group). This field is displayed only when 'Specific User' value is picked in the 'Security Level' field. Otherwise this field is hidden.

    3. Title (Single line of text)

    4. Description (Multiple lines of text)

    5. Company (Lookup). This field retrieves Company values from another List in the site.

    The WSS site uses Forms Based Authentication.  Please let me know if you need any other info (web.config file settings, IIS, etc.).

    Thanks again.

    Kiran

    Monday, March 08, 2010 4:32 PM
  • Ashish,

    We did modify the 'default.master' Page. Some code blocks were commented out. I have attached the Master Page code. Not sure if this is causing the 'Code blocks are not allowed in this file.' error.

    Also, I tried the following slightly different PageParserPath settings in the web.config file, but still got the same 'Code blocks..." error. This time, I specified the path to the custom 'NewForm.aspx' file in the List. The custom file is titled: CustomNewForm.aspx


    <PageParserPaths>

    <
    PageParserPath VirtualPath="/NEW%20Download%20Manager/CustomNewForm.aspx" CompilationMode="Always" AllowServerSideScript="true" />

     

    </

     

    PageParserPaths>

    'Default.master' Page code:

    <%@Master language="C#"%>
    <%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Import Namespace="Microsoft.SharePoint" %>
    <%@ Import Namespace="Microsoft.SharePoint.ApplicationPages" %>
    <%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
    <%@ Register TagPrefix="wssuc" TagName="Welcome" src="~/_controltemplates/Welcome.ascx" %>
    <%@ Register TagPrefix="wssuc" TagName="DesignModeConsole" src="~/_controltemplates/DesignModeConsole.ascx" %>
    <HTML dir="<%$Resources:wss,multipages_direction_dir_value%>" runat="server" xmlns:o="urn:schemas-microsoft-com:office:office" __expr-val-dir="ltr">
    <HEAD runat="server">
    	<META Name="GENERATOR" Content="Microsoft SharePoint">
    	<META Name="progid" Content="SharePoint.WebPartPage.Document">
    	<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
    	<META HTTP-EQUIV="Expires" content="0">
    	<SharePoint:RobotsMetaTag runat="server"/>
    	<Title ID=onetidTitle><asp:ContentPlaceHolder id=PlaceHolderPageTitle runat="server"/></Title>
    	<SharePoint:CssLink runat="server"/>
    	<SharePoint:Theme runat="server"/>
    	<SharePoint:ScriptLink language="javascript" name="core.js" Defer="true" runat="server"/>
    	<SharePoint:CustomJSUrl runat="server"/>
    	<SharePoint:SoapDiscoveryLink runat="server"/>
    	<asp:ContentPlaceHolder id="PlaceHolderAdditionalPageHead" runat="server"/>
    	<SharePoint:DelegateControl runat="server" ControlId="AdditionalPageHead" AllowMultipleControls="true"/>
    	
    	<meta name="Microsoft Theme" content="simple 1011, default">
    </HEAD>
    <BODY scroll="yes" onload="javascript:if (typeof(_spBodyOnLoadWrapper) != 'undefined') _spBodyOnLoadWrapper();">
     	<link rel="stylesheet" type="text/css" href="/_catalogs/masterpage/nttstyles.css">
     <form runat="server" onsubmit="return _spFormOnSubmitWrapper();">
    	<WebPartPages:SPWebPartManager id="m" runat="Server"/>
    	<asp:ScriptManager runat="server" ID="ScriptManager1"></asp:ScriptManager>
      <TABLE class="ms-main" CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="100%" HEIGHT="100%">
    	<tr><td><asp:ContentPlaceHolder id="PlaceHolderGlobalNavigation" runat="server">
    		<table CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="100%" height="20px">
    		<tr>
    		 <td colspan=4 class="ntt-globalbreadcrumb">
    			<span id="TurnOnAccessibility" style="display:none">
    			   <a href="#" class="ms-skip" onclick="SetIsAccessibilityFeatureEnabled(true);UpdateAccessibilityUI();return false;">
    			<SharePoint:EncodedLiteral runat="server" text="<%$Resources:wss,master_turnonaccessibility%>" EncodeMethod="HtmlEncode"/></a>
    			</span>
    			<A href="javascript:;" onclick="javascript:this.href='#mainContent';" class="ms-skip" AccessKey="<%$Resources:wss,maincontent_accesskey%>" runat="server">
    			<SharePoint:EncodedLiteral runat="server" text="<%$Resources:wss,mainContentLink%>" EncodeMethod="HtmlEncode"/></A>
    		 <!--<table cellpadding=0 cellspacing=0 height=100% class="ms-globalleft">
    		   <tr>
    			<td class="ntt-globallinks" style="padding-top: 2px;" height=100% valign=middle>
    			 <div>
    			  <span id="TurnOffAccessibility" style="display:none">
    				<a href="#" class="ms-acclink" onclick="SetIsAccessibilityFeatureEnabled(false);UpdateAccessibilityUI();return false;">
    				<SharePoint:EncodedLiteral runat="server" text="<%$Resources:wss,master_turnoffaccessibility%>" EncodeMethod="HtmlEncode" __designer:Preview="Turn off more accessible mode" __designer:Values="&lt;P N='Text' Bound='True' T='Resources:wss,master_turnoffaccessibility' /&gt;&lt;P N='ID' T='ctl09' /&gt;&lt;P N='Page' ID='1' /&gt;&lt;P N='TemplateControl' ID='2' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;"/></a>
    			  </span>
    			  <asp:ContentPlaceHolder id="PlaceHolderGlobalNavigationSiteMap" runat="server">
    				<asp:SiteMapPath SiteMapProvider="SPSiteMapProvider" id="GlobalNavigationSiteMap" RenderCurrentNodeAsLink="true" SkipLinkText="" NodeStyle-CssClass="ms-sitemapdirectional" runat="server" __designer:Preview="&lt;span id=&quot;ctl00_GlobalNavigationSiteMap&quot;&gt;&lt;span&gt;&lt;a class=&quot;ms-sitemapdirectional&quot; href=&quot;/&quot;&gt;KnowledgeHub&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;" __designer:Values="&lt;P N='SiteMapProvider' T='SPSiteMapProvider' /&gt;&lt;P N='NodeStyle'&gt;&lt;P N='CssClass' T='ms-sitemapdirectional' /&gt;&lt;P N='IsEmpty' T='False' /&gt;&lt;/P&gt;&lt;P N='RenderCurrentNodeAsLink' T='True' /&gt;&lt;P N='SkipLinkText' R='-1' /&gt;&lt;P N='ControlStyle'&gt;&lt;P N='Font' ID='1' /&gt;&lt;/P&gt;&lt;P N='Font' R='1' /&gt;&lt;P N='ID' T='GlobalNavigationSiteMap' /&gt;&lt;P N='Page' ID='2' /&gt;&lt;P N='TemplateControl' ID='3' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;" __designer:Templates="&lt;Group Name=&quot;NodeTemplate&quot;&gt;&lt;Template Name=&quot;NodeTemplate&quot; Content=&quot;&quot; /&gt;&lt;/Group&gt;&lt;Group Name=&quot;CurrentNodeTemplate&quot;&gt;&lt;Template Name=&quot;CurrentNodeTemplate&quot; Content=&quot;&quot; /&gt;&lt;/Group&gt;&lt;Group Name=&quot;RootNodeTemplate&quot;&gt;&lt;Template Name=&quot;RootNodeTemplate&quot; Content=&quot;&quot; /&gt;&lt;/Group&gt;&lt;Group Name=&quot;PathSeparatorTemplate&quot;&gt;&lt;Template Name=&quot;PathSeparatorTemplate&quot; Content=&quot;&quot; /&gt;&lt;/Group&gt;"/>
    			  </asp:ContentPlaceHolder>
    			  </div>
    			 </td>
    		   </tr>
    		 </table>-->
    		 
    			</td>
    		   </tr>
    	   </table>
    	  </asp:ContentPlaceHolder></td></tr>
    	<tr>
    	 <td class="ntt-globalTitleArea">
    	  <table width=100% cellpadding=0 cellspacing=0 border=0>
    	   <tr>
    		<td id="GlobalTitleAreaImage" class="ms-titleimagearea">
    		<SharePoint:SiteLogoImage id="onetidHeadbnnr0" LogoImageUrl="/_layouts/images/titlegraphic.gif" runat="server"/></td>
    		<td class="ntt-sitetitle" width=100%>
    		  <asp:ContentPlaceHolder id="PlaceHolderSiteName" runat="server">
    			<h1 class="ntt-sitetitle">
    		   <SharePoint:SPLinkButton runat="server" NavigateUrl="~site/" id="onetidProjectPropertyTitle"><SharePoint:ProjectProperty Property="Title" runat="server" /></SharePoint:SPLinkButton>
    		  </h1>
    		  </asp:ContentPlaceHolder>
    		</td>
    		<td style="padding-top:8px;" valign=top><table cellpadding="0" cellspacing="0" height=100% class="ntt-globalright">
    		  <tr>
    			  <td valign="middle" class="ntt-globallinks" style="padding-left:3px; padding-right:6px;">
    			  <SharePoint:DelegateControl runat="server" ControlId="GlobalSiteLink0"/>
    			  </td>
    		  <td valign="middle" class="ntt-globallinks">
    			<wssuc:Welcome id="IdWelcome" runat="server" EnableViewState="false">
    			</wssuc:Welcome>
    		  </td>
    		  <td style="padding-left:1px;padding-right:3px;" class="ntt-globallinks"></td>
    			  <!--<td valign="middle" class="ntt-globallinks">
    				<table cellspacing="0" cellpadding="0">
    				 <tr>
    				  <td class="ntt-globallinks">
    					<SharePoint:DelegateControl ControlId="GlobalSiteLink1" Scope="Farm" runat="server" __designer:Preview="&lt;span style=&quot;display:none&quot;&gt;&lt;/span&gt;" __designer:Values="&lt;P N='ControlId' T='GlobalSiteLink1' /&gt;&lt;P N='Scope' T='Farm' /&gt;&lt;P N='ID' T='ctl12' /&gt;&lt;P N='Page' ID='1' /&gt;&lt;P N='TemplateControl' ID='2' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;"/></td>
    				  <td class="ntt-globallinks">
    					<SharePoint:DelegateControl ControlId="GlobalSiteLink2" Scope="Farm" runat="server" __designer:Preview="&lt;span style=&quot;display:none&quot;&gt;&lt;/span&gt;" __designer:Values="&lt;P N='ControlId' T='GlobalSiteLink2' /&gt;&lt;P N='Scope' T='Farm' /&gt;&lt;P N='ID' T='ctl13' /&gt;&lt;P N='Page' ID='1' /&gt;&lt;P N='TemplateControl' ID='2' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;"/></td>
    				 </tr>
    				</table>
    			  </td>
    			  <td valign="middle" class="ntt-globallinks">&nbsp;
    				<a href="javascript:TopHelpButtonClick('NavBarHelpHome')" AccessKey="<%$Resources:wss,multipages_helplink_accesskey%>" id="TopHelpLink" title="<%$Resources:wss,multipages_helplinkalt_text%>" runat="server"><img align='absmiddle' border=0 src="/_layouts/images/helpicon.gif" alt="<%$Resources:wss,multipages_helplinkalt_text%>" runat="server"></a>
    			  </td>-->
    			  </tr>
    			</table>
    		  <asp:ContentPlaceHolder id="PlaceHolderSearchArea" runat="server">
    				<SharePoint:DelegateControl runat="server" ControlId="SmallSearchInputBox"/>
    		  </asp:ContentPlaceHolder>
    		</td>
    	   </tr>
    	  </table>
    	 </td>
    	</tr>
    	<TR>
    	 <TD id="onetIdTopNavBarContainer" WIDTH=100% class="ntt-bannerContainer">
    		<asp:ContentPlaceHolder id="PlaceHolderTopNavBar" runat="server">
    			<table class="ntt-bannerframe" border="0" cellspacing="0" cellpadding="0" width="100%">
    		   <tr>
    			<td nowrap valign="middle"></td>
    			<td class=ms-banner width=99% nowrap ID="HBN100">
    				<asp:ContentPlaceHolder id="PlaceHolderHorizontalNav" runat="server">
    	<SharePoint:AspMenu
    	  ID="TopNavigationMenu"
    	  Runat="server"
    	  DataSourceID="topSiteMap"
    	  EnableViewState="false"
    	  AccessKey="<%$Resources:wss,navigation_accesskey%>"
    	  Orientation="Horizontal"
    	  StaticDisplayLevels="2"
    	  MaximumDynamicDisplayLevels="1"
    	  DynamicHorizontalOffset="0"
    	 
    	  StaticPopoutImageTextFormatString=""
    	  DynamicHoverStyle-BackColor="#CBE3F0"
    	  SkipLinkText=""
    	  StaticSubMenuIndent="0"
    	  CssClass="ntt-topNavContainer"><StaticMenuStyle/><StaticMenuItemStyle CssClass="ntt-topnav" ItemSpacing="0px"/><StaticSelectedStyle CssClass="ntt-topnavselected" /><StaticHoverStyle CssClass="ntt-topNavHover" /><DynamicMenuStyle  BackColor="#F2F3F4" BorderColor="#A7B4CE" BorderWidth="1px"/><DynamicMenuItemStyle CssClass="ms-topNavFlyOuts"/><DynamicHoverStyle CssClass="ms-topNavFlyOutsHover"/><DynamicSelectedStyle CssClass="ms-topNavFlyOutsSelected"/></SharePoint:AspMenu>
    	<SharePoint:DelegateControl runat="server" ControlId="TopNavigationDataSource"><Template_Controls>
    			<asp:SiteMapDataSource
    			  ShowStartingNode="False"
    			  SiteMapProvider="SPNavigationProvider"
    			  id="topSiteMap"
    			  runat="server"
    			  StartingNodeUrl="sid:1002"/>
    		</Template_Controls></SharePoint:DelegateControl>
    				</asp:ContentPlaceHolder>
    			</td>
    			<td class=ms-banner>&nbsp;&nbsp;</td>
    			<td valign=bottom align=right style="position:relative;bottom:0;left:0;">
    			 <table cellpadding=0 cellspacing=0 border=0>
    			  <tr>
    			   <td>
    				<table height=100% class="ms-siteaction" cellpadding=0 cellspacing=0>
    				 <tr>
    					   <td class="ms-siteactionsmenu" id="siteactiontd">
    					   <SharePoint:SiteActions runat="server" AccessKey="<%$Resources:wss,tb_SiteActions_AK%>" id="SiteActionsMenuMain"
    						PrefixHtml="&lt;div&gt;&lt;div&gt;"
    						SuffixHtml="&lt;/div&gt;&lt;/div&gt;"
    						MenuNotVisibleHtml="&amp;nbsp;"><CustomTemplate>
    						<SharePoint:FeatureMenuTemplate runat="server"
    							FeatureScope="Site"
    							Location="Microsoft.SharePoint.StandardMenu"
    							GroupId="SiteActions"
    							UseShortId="true"
    							>
    							<SharePoint:MenuItemTemplate runat="server" id="MenuItem_Create"
    								Text="<%$Resources:wss,viewlsts_pagetitle_create%>"
    								Description="<%$Resources:wss,siteactions_createdescription%>"
    								ImageUrl="/_layouts/images/Actionscreate.gif"
    								MenuGroupId="100"
    								Sequence="100"
    								UseShortId="true"
    								ClientOnClickNavigateUrl="~site/_layouts/create.aspx"
    								PermissionsString="ManageLists, ManageSubwebs"
    								PermissionMode="Any" />
    							<SharePoint:MenuItemTemplate runat="server" id="MenuItem_EditPage"
    								Text="<%$Resources:wss,siteactions_editpage%>"
    								Description="<%$Resources:wss,siteactions_editpagedescription%>"
    								ImageUrl="/_layouts/images/ActionsEditPage.gif"
    								MenuGroupId="100"
    								Sequence="200"
    								ClientOnClickNavigateUrl="javascript:MSOLayout_ChangeLayoutMode(false);"
    								/>
    							<SharePoint:MenuItemTemplate runat="server" id="MenuItem_Settings"
    								Text="<%$Resources:wss,settings_pagetitle%>"
    								Description="<%$Resources:wss,siteactions_sitesettingsdescription%>"
    								ImageUrl="/_layouts/images/ActionsSettings.gif"
    								MenuGroupId="100"
    								Sequence="300"
    								UseShortId="true"
    								ClientOnClickNavigateUrl="~site/_layouts/settings.aspx"
    								PermissionsString="EnumeratePermissions,ManageWeb,ManageSubwebs,AddAndCustomizePages,ApplyThemeAndBorder,ManageAlerts,ManageLists,ViewUsageData"
    								PermissionMode="Any" />
    						</SharePoint:FeatureMenuTemplate>
    						</CustomTemplate></SharePoint:SiteActions>
    					</td>
    				 </tr>
    				</table>
    			   </td>
    			  </tr>
    			 </table>
    			</td>
    		   </tr>
    		  </table>
    		</asp:ContentPlaceHolder>
    	 </TD>
    	</TR>
    	<asp:ContentPlaceHolder ID="WSSDesignConsole" runat="server">
    		<wssuc:DesignModeConsole id="IdDesignModeConsole" runat="server"/>
    	</asp:ContentPlaceHolder>
    	<asp:ContentPlaceHolder ID="SPNavigation" runat="server">
    	</asp:ContentPlaceHolder>
    	<TR height="100%"><TD><TABLE width="100%" height="100%" cellspacing="0" cellpadding="0">
    	<tr>
    	 <td class="ms-titlearealeft" id="TitleAreaImageCell" valign="middle" nowrap><div style="height:100%" class="ms-titleareaframe"><asp:ContentPlaceHolder id="PlaceHolderPageImage" runat="server"/></div></td>
    	 <td class="ms-titleareaframe" id="TitleAreaFrameClass">
    	  <asp:ContentPlaceHolder id="PlaceHolderTitleLeftBorder" runat="server">
    		<div class="ms-titleareaframe"><IMG SRC="/_layouts/images/blank.gif" width=1 height=100% alt=""></div>
    	  </asp:ContentPlaceHolder>
    	 </td>
    	<td valign=top id="onetidPageTitleAreaFrame" class='ms-pagetitleareaframe' nowrap>
    	  <table id="onetidPageTitleAreaTable" cellpadding=0 cellspacing=0 width=100% border="0">
    	   <tr>
    		<td valign="top" class="ms-titlearea">
    		 <asp:ContentPlaceHolder id="PlaceHolderTitleBreadcrumb" runat="server">
    			<asp:SiteMapPath SiteMapProvider="SPContentMapProvider" id="ContentMap" SkipLinkText="" NodeStyle-CssClass="ms-sitemapdirectional" runat="server"/> &nbsp;
    		 </asp:ContentPlaceHolder>
    		</td>
    	   </tr>
    	   <tr>
    		<td height=100% valign=top ID=onetidPageTitle class="ms-pagetitle">
    		  <h2 class="ms-pagetitle">
    			<asp:ContentPlaceHolder id="PlaceHolderPageTitleInTitleArea" runat="server" >
    			</asp:ContentPlaceHolder>
    		  </h2>
    		</td>
    	   </tr>
    	  </table>
    	 </td>
    	 <td class="ms-titlearearight">
    		<asp:ContentPlaceHolder id="PlaceHolderMiniConsole" runat="server"/>
    		<asp:ContentPlaceHolder id="PlaceHolderTitleRightMargin" runat="server">
    <div class="ms-titleareaframe" style='height:100%'><IMG SRC="/_layouts/images/blank.gif" width=1 height=1 alt=""></div>
    </asp:ContentPlaceHolder></td>
    	</tr>
    <asp:ContentPlaceHolder id="PlaceHolderTitleAreaSeparator" runat="server"/>
    	<TR>
    	  <TD class="ms-leftareacell" valign=top height=100% id="LeftNavigationAreaCell">
    	   <table class=ms-nav width=100% height=100% cellpadding=0 cellspacing=0>
    		<tr>
    		 <td>
    		  <TABLE height="100%" class=ms-navframe CELLPADDING=0 CELLSPACING=0 border="0">
    		   <tr valign="top">
    			<td width="4px"><IMG SRC="/_layouts/images/blank.gif" width=4 height=1 alt=""></td>
    			<td valign="top" width="100%">
    			  <asp:ContentPlaceHolder id="PlaceHolderLeftNavBarDataSource" runat="server" />
    			  <asp:ContentPlaceHolder id="PlaceHolderCalendarNavigator" runat="server" />
    			  <asp:ContentPlaceHolder id="PlaceHolderLeftNavBarTop" runat="server"/>
    			  <asp:ContentPlaceHolder id="PlaceHolderLeftNavBar" runat="server">
    				<div class="ms-quicklaunchouter">
    				<div class="ms-quickLaunch" style="width:100%">
    				<h3 class="ms-standardheader"><label class="ms-hidden">
    				<SharePoint:EncodedLiteral runat="server" text="<%$Resources:wss,quiklnch_pagetitle%>" EncodeMethod="HtmlEncode"/></label>
    				<!--<Sharepoint:SPSecurityTrimmedControl runat="server" PermissionsString="ViewFormPages" __designer:Preview="&lt;span&gt;&lt;div class=&quot;ms-quicklaunchheader&quot;&gt;&lt;a id=&quot;ctl00_idNavLinkViewAll&quot; accesskey=&quot;3&quot; href=&quot;/_layouts/viewlsts.aspx&quot;&gt;View All Site Content&lt;/a&gt;&lt;/div&gt;&lt;/span&gt;" __designer:Values="&lt;P N='Permissions' E='4096' /&gt;&lt;P N='PermissionsString' T='ViewFormPages' /&gt;&lt;P N='ControlStyle'&gt;&lt;P N='Font' ID='1' /&gt;&lt;/P&gt;&lt;P N='Font' R='1' /&gt;&lt;P N='ID' T='ctl20' /&gt;&lt;P N='Page' ID='2' /&gt;&lt;P N='TemplateControl' ID='3' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;"><div class="ms-quicklaunchheader"><SharePoint:SPLinkButton id="idNavLinkViewAll" runat="server" NavigateUrl="~site/_layouts/viewlsts.aspx" Text="<%$Resources:wss,quiklnch_allcontent%>" AccessKey="<%$Resources:wss,quiklnch_allcontent_AK%>"/></div></SharePoint:SPSecurityTrimmedControl>-->
    				</h3>
    				<Sharepoint:SPNavigationManager
    				id="QuickLaunchNavigationManager"
    				runat="server"
    				QuickLaunchControlId="QuickLaunchMenu"
    				ContainedControl="QuickLaunch"
    				EnableViewState="false">
    				<div>
    					<SharePoint:DelegateControl runat="server" ControlId="QuickLaunchDataSource">
    						<Template_Controls>
    						<asp:SiteMapDataSource SiteMapProvider="SPNavigationProvider" ShowStartingNode="False" id="QuickLaunchSiteMap" StartingNodeUrl="sid:1025" runat="server" />
    					 </Template_Controls>
    					</SharePoint:DelegateControl>
    					<SharePoint:AspMenu id="QuickLaunchMenu" DataSourceId="QuickLaunchSiteMap" runat="server" Orientation="Vertical" StaticDisplayLevels="2" ItemWrap="true" MaximumDynamicDisplayLevels="0" StaticSubMenuIndent="0" SkipLinkText="">
    						<LevelMenuItemStyles>
    							<asp:menuitemstyle CssClass="ms-navheader" />
    							<asp:menuitemstyle CssClass="ms-navitem" />
    						</LevelMenuItemStyles>
    						<LevelSubMenuStyles>
    							<asp:submenustyle CssClass="ms-navSubMenu1" />
    							<asp:submenustyle CssClass="ms-navSubMenu2" />
    						</LevelSubMenuStyles>
    						<LevelSelectedStyles>
    							<asp:menuitemstyle CssClass="ms-selectednavheader" />
    							<asp:menuitemstyle CssClass="ms-selectednav" />
    						</LevelSelectedStyles>
    					</SharePoint:AspMenu>
    				</div>
    				</Sharepoint:SPNavigationManager>
    				<Sharepoint:SPNavigationManager
    				id="TreeViewNavigationManager"
    				runat="server"
    				ContainedControl="TreeView"><table class="ms-navSubMenu1" cellpadding="0" cellspacing="0" border="0"><tr><td><table class="ms-navheader" width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td nowrap id="idSiteHierarchy"><SharePoint:SPLinkButton runat="server" NavigateUrl="~site/_layouts/viewlsts.aspx" id="idNavLinkSiteHierarchy" Text="<%$Resources:wss,treeview_header%>" AccessKey="<%$Resources:wss,quiklnch_allcontent_AK%>"/></td></tr></table></td></tr></table><div class="ms-treeviewouter"><SharePoint:SPHierarchyDataSourceControl
    					 runat="server"
    					 id="TreeViewDataSource"
    					 RootContextObject="Web"
    					 IncludeDiscussionFolders="true"
    					/><SharePoint:SPRememberScroll runat="server" id="TreeViewRememberScroll" onscroll="javascript:_spRecordScrollPositions(this);" Style="overflow: auto;height: 400px;width: 150px; "><Sharepoint:SPTreeView
    						id="WebTreeView"
    						runat="server"
    						ShowLines="false"
    						DataSourceId="TreeViewDataSource"
    						ExpandDepth="0"
    						SelectedNodeStyle-CssClass="ms-tvselected"
    						NodeStyle-CssClass="ms-navitem"
    						NodeStyle-HorizontalPadding="2"
    						SkipLinkText=""
    						NodeIndent="12"
    						ExpandImageUrl="/_layouts/images/tvplus.gif"
    						CollapseImageUrl="/_layouts/images/tvminus.gif"
    						NoExpandImageUrl="/_layouts/images/tvblank.gif"
    					>
    					</Sharepoint:SPTreeView></Sharepoint:SPRememberScroll></div></Sharepoint:SPNavigationManager>
    				<table width="100%" cellpadding="0" cellspacing="0" border="0">
    				<tr><td>
    		<table class="ms-recyclebin" width="100%" cellpadding="0" cellspacing="0" border="0">
    		<tr><td nowrap>
    		<SharePoint:SPLinkButton runat="server" NavigateUrl="~site/_layouts/recyclebin.aspx" id="idNavLinkRecycleBin" ImageUrl="/_layouts/images/recycbin.gif" Text="<%$Resources:wss,StsDefault_RecycleBin%>" PermissionsString="DeleteListItems"/>
    		</td></tr>
    		</table>
    		</td></tr></table>
    				</div>
    				</div>
    			  </asp:ContentPlaceHolder>
    			  <asp:ContentPlaceHolder id="PlaceHolderLeftActions" runat="server"></asp:ContentPlaceHolder>
    			</td>
    		   </tr>
    		   <tr><td colspan=2><asp:ContentPlaceHolder id="PlaceHolderNavSpacer" runat="server"><IMG SRC="/_layouts/images/blank.gif" width=138 height=1 alt=""></asp:ContentPlaceholder></td></tr>
    		  </TABLE>
    		 </td>
    		 <td><asp:ContentPlaceHolder id="PlaceHolderLeftNavBarBorder" runat="server"></asp:ContentPlaceHolder></td>
    		</tr>
    	   </table>
    	  </TD>
    	  <td><asp:ContentPlaceHolder id="PlaceHolderBodyLeftBorder" runat="server">
    <div class="ms-pagemargin"><IMG SRC="/_layouts/images/blank.gif" width=10 height=1 alt=""></div>
    </asp:ContentPlaceHolder></td>
    	  <td class='ms-bodyareacell' valign="top">
    		<PlaceHolder id="MSO_ContentDiv" runat="server">
    		<table id="MSO_ContentTable" width=100% height="100%" border="0" cellspacing="0" cellpadding="0" class="ms-propertysheet">
    		  <tr>
    			 <td class='ms-bodyareaframe' valign="top" height="100%">
    			   <A name="mainContent"></A>
    				<asp:ContentPlaceHolder id="PlaceHolderPageDescription" runat="server"/>
    				<asp:ContentPlaceHolder id="PlaceHolderMain" runat="server">
    				</asp:ContentPlaceHolder>
    			 </td>
    		  </tr>
    		</table>
    		</PlaceHolder>
    	  </td>
    	  <td class="ms-rightareacell"><asp:ContentPlaceHolder id="PlaceHolderBodyRightMargin" runat="server">
    <div class="ms-pagemargin"><IMG SRC="/_layouts/images/blank.gif" width=10 height=1 alt=""></div>
    </asp:ContentPlaceHolder></td>
    	</TR>
    <tr>
    	<td class="ms-pagebottommarginleft"><IMG SRC="/_layouts/images/blank.gif" width=1 height=10 alt=""></td>
    	<td class="ms-pagebottommargin"><IMG SRC="/_layouts/images/blank.gif" width=1 height=10 alt=""></td>
    	<td class="ms-bodyareapagemargin"><IMG SRC="/_layouts/images/blank.gif" width=1 height=10 alt=""></td>
    	<td class="ms-pagebottommarginright"><IMG SRC="/_layouts/images/blank.gif" width=1 height=10 alt=""></td>
    </tr>
    	</TABLE></TD></TR>
      </TABLE>
      <asp:ContentPlaceHolder id="PlaceHolderFormDigest" runat="server">
    		<SharePoint:FormDigest runat=server/>
      </asp:ContentPlaceHolder>
       <input type="text" name="__spDummyText1" style="display:none;" size=1/>
       <input type="text" name="__spDummyText2" style="display:none;" size=1/>
      </form>
      <asp:ContentPlaceHolder id="PlaceHolderUtilityContent" runat="server"/>
    	<asp:ContentPlaceHolder id="PlaceHolderBodyAreaClass" runat="server"/>
    	<asp:ContentPlaceHolder id="PlaceHolderTitleAreaClass" runat="server"/>
    </BODY>
    </HTML>
    
    Monday, March 08, 2010 6:57 PM
  • Hi Ashish,

    I got this working using an alternate approach.

    I created a SmartPart Web Part (http://www.codeplex.com/smartpart) which runs on 'Page_Load' event and retrieves the 'Company' value for the user from the database and stores it in a text field. I then added the SmartPart Web Part on top my custom NewForm.aspx page, and then hid it.

    I then added JavaScript code to retrieve the Company value from the text field in the 'hidden' SmartPart Web Part and set it in the 'Company' field in the custom NewForm.aspx page.

    Best regards,

    Kiran

    • Marked as answer by Seven M Thursday, March 11, 2010 2:17 AM
    Tuesday, March 09, 2010 5:48 PM
  • Glad to know you resolved the issue

    Good Luck
    Ashish Kanoongo, MCP, MCSD, MCTS
    Tuesday, March 09, 2010 5:53 PM
  • Kiran,

    Can you please let me know how you acheived it using SmartPart in details.

     


    Regards, Aj (http://www.aj-sharepoint.blogspot.com/) MCTS
    Thursday, April 22, 2010 6:30 AM