Reply
Exists but not recognizing...
Old 12-20-2006, 01:00 PM Exists but not recognizing...
Junior Talker

Posts: 2
Name: Jared
Location: Illinois
I'm getting the following error when I deploy this. It runs fine locally. "username" is defined in the codebehind file but for some reason its not getting recognized. Any help?

Server Error in '/wwwroot' 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: CS0103: The name 'username' does not exist in the class or namespace 'ASP.projecthome_aspx'

Source Error:

Line 17: <td><CLI:Header id="Header" runat="server"></CLI:Header>Line 18: </td>Line 19: <td width="75%" align="right" valign="top"><div id="SignedIn">Logged in as: <%=username%><br>Position: <%=positionId%></div><br>Line 20: <a href="Logout.aspx">logout</a></td>Line 21: </tr>
Source File: d:\hosting\jstrockbine77\wwwroot\ProjectManager.Ap p\ProjectHome.aspx Line: 19



Show Detailed Compiler Output:

c:\windows\system32\inetsrv> "c:\windows\microsoft.net\framework\v1.1.4322\csc. exe" /t:library /utf8output /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\jxymlbfd.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\assembly\dl2\ddf1d afd\f33f4ed9_5f24c701\pm.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\assembly\dl2\926dc 326\ab596cda_5f24c701\project_manager.class.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\assembly\dl2\758c0 35e\72e953d8_5f24c701\mlm.class.utils.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\assembly\dl2\79333 d62\3904b4ad_a623c701\rssclient.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\ms corlib.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\assembly\dl2\54a64 4b7\2c2b0d4b_8423c701\hogblog.dll" /R:"c:\windows\assembly\gac\system.drawing\1.0.5000 .0__b03f5f7f11d50a3a\system.drawing.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\wwwroot\416a8ad4\acbc3f43\lzjhv2hg.dll" /R:"c:\windows\assembly\gac\system.xml\1.0.5000.0__ b77a5c561934e089\system.xml.dll" /R:"c:\windows\assembly\gac\system.web.services\1.0 .5000.0__b03f5f7f11d50a3a\system.web.services.dll" /R:"c:\windows\assembly\gac\system.web.mobile\1.0.5 000.0__b03f5f7f11d50a3a\system.web.mobile.dll" /R:"c:\windows\assembly\gac\system.data\1.0.5000.0_ _b77a5c561934e089\system.data.dll" /R:"c:\windows\assembly\gac\system.enterpriseservic es\1.0.5000.0__b03f5f7f11d50a3a\system.enterprises ervices.dll" /R:"c:\windows\assembly\gac\system\1.0.5000.0__b77a 5c561934e089\system.dll" /R:"c:\windows\assembly\gac\system.web\1.0.5000.0__ b03f5f7f11d50a3a\system.web.dll" /out:"c:\windows\microsoft.net\framework\v1.1.4322\ Temporary ASP.NET Files\wwwroot\416a8ad4\acbc3f43\jsk2tvvw.dll" /DEBUG /debug+ /optimize- /win32res:"c:\windows\microsoft.net\framework\v1.1. 4322\Temporary ASP.NET Files\wwwroot\416a8ad4\acbc3f43\jsk2tvvw.res" /warnaserror /w:1 "c:\windows\microsoft.net\framework\v1.1.4322\Temp orary ASP.NET Files\wwwroot\416a8ad4\acbc3f43\jsk2tvvw.0.cs"Micr osoft (R) Visual C# .NET Compiler version 7.10.6310.4for Microsoft (R) .NET Framework version 1.1.4322Copyright (C) Microsoft Corporation 2001-2002. All rights reserved.d:\hosting\jstrockbine77\wwwroot\ProjectM anager.App\ProjectHome.aspx(19,28): error CS0103: The name 'username' does not exist in the class or namespace 'ASP.projecthome_aspx'd:\hosting\jstrockbine77\www root\ProjectManager.App\ProjectHome.aspx(19,28): error CS0103: The name 'positionId' does not exist in the class or namespace 'ASP.projecthome_aspx'



Show Complete Compilation Source:

Line 1: //------------------------------------------------------------------------------Line 2: // <autogenerated>Line 3: // This code was generated by a tool.Line 4: // Runtime Version: 1.1.4322.2300Line 5: //Line 6: // Changes to this file may cause incorrect behavior and will be lost if Line 7: // the code is regenerated.Line 8: // </autogenerated>Line 9: //------------------------------------------------------------------------------Line 10: Line 11: namespace ASP {Line 12: using System;Line 13: using System.Collections;Line 14: using System.Collections.Specialized;Line 15: using System.Configuration;Line 16: using System.Text;Line 17: using System.Text.RegularExpressions;Line 18: using System.Web;Line 19: using System.Web.Caching;Line 20: using System.Web.SessionState;Line 21: using System.Web.Security;Line 22: using System.Web.UI;Line 23: using System.Web.UI.WebControls;Line 24: using System.Web.UI.HtmlControls;Line 25: using ASP;Line 26: Line 27: Line 28: [System.Runtime.CompilerServices.CompilerGlobalScop eAttribute()]Line 29: public class projecthome_aspx : PM.projecthome, System.Web.SessionState.IRequiresSessionState {Line 30: Line 31: Line 32: #line 17 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 33: protected ASP.header_ascx Header;Line 34: Line 35: #line defaultLine 36: #line hiddenLine 37: Line 38: private static bool __initialized = false;Line 39: Line 40: private static object __stringResource;Line 41: Line 42: private static System.Collections.ArrayList __fileDependencies;Line 43: Line 44: public projecthome_aspx() {Line 45: System.Collections.ArrayList dependencies;Line 46: if ((ASP.projecthome_aspx.__initialized == false)) {Line 47: ASP.projecthome_aspx.__stringResource = System.Web.UI.TemplateControl.ReadStringResource(t ypeof(ASP.projecthome_aspx));Line 48: dependencies = new System.Collections.ArrayList();Line 49: dependencies.Add("d:\\hosting\\jstrockbine77\\wwwr oot\\bin\\PM.DLL");Line 50: dependencies.Add("d:\\hosting\\jstrockbine77\\wwwr oot\\ProjectManager.App\\ProjectHome.aspx");Line 51: dependencies.Add("d:\\hosting\\jstrockbine77\\wwwr oot\\ProjectManager.App\\controls\\header.ascx");L ine 52: ASP.projecthome_aspx.__fileDependencies = dependencies;Line 53: ASP.projecthome_aspx.__initialized = true;Line 54: }Line 55: this.Server.ScriptTimeout = 30000000;Line 56: }Line 57: Line 58: protected override bool SupportAutoEvents {Line 59: get {Line 60: return false;Line 61: }Line 62: }Line 63: Line 64: protected ASP.Global_asax ApplicationInstance {Line 65: get {Line 66: return ((ASP.Global_asax)(this.Context.ApplicationInstanc e));Line 67: }Line 68: }Line 69: Line 70: public override string TemplateSourceDirectory {Line 71: get {Line 72: return "/wwwroot/ProjectManager.App";Line 73: }Line 74: }Line 75: Line 76: private System.Web.UI.Control __BuildControlHeader() {Line 77: ASP.header_ascx __ctrl;Line 78: Line 79: #line 17 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 80: __ctrl = new ASP.header_ascx();Line 81: Line 82: #line defaultLine 83: #line hiddenLine 84: this.Header = __ctrl;Line 85: Line 86: #line 17 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 87: this.Header.InitializeAsUserControl(this.Page);Lin e 88: Line 89: #line defaultLine 90: #line hiddenLine 91: Line 92: #line 17 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 93: __ctrl.ID = "Header";Line 94: Line 95: #line defaultLine 96: #line hiddenLine 97: return __ctrl;Line 98: }Line 99: Line 100: private System.Web.UI.Control __BuildControlfrmMain() {Line 101: System.Web.UI.HtmlControls.HtmlForm __ctrl;Line 102: Line 103: #line 13 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 104: __ctrl = new System.Web.UI.HtmlControls.HtmlForm();Line 105: Line 106: #line defaultLine 107: #line hiddenLine 108: this.frmMain = __ctrl;Line 109: Line 110: #line 13 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 111: __ctrl.ID = "frmMain";Line 112: Line 113: #line defaultLine 114: #line hiddenLine 115: Line 116: #line 13 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 117: __ctrl.Method = "post";Line 118: Line 119: #line defaultLine 120: #line hiddenLine 121: Line 122: #line 13 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 123: this.__BuildControlHeader();Line 124: Line 125: #line defaultLine 126: #line hiddenLine 127: System.Web.UI.IParserAccessor __parser = ((System.Web.UI.IParserAccessor)(__ctrl));Line 128: Line 129: #line 13 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 130: __parser.AddParsedSubObject(this.Header);Line 131: Line 132: #line defaultLine 133: #line hiddenLine 134: __ctrl.SetRenderMethodDelegate(new System.Web.UI.RenderMethod(this.__RenderfrmMain)); Line 135: return __ctrl;Line 136: }Line 137: Line 138: private void __RenderfrmMain(System.Web.UI.HtmlTextWriter __output, System.Web.UI.Control parameterContainer) {Line 139: __output.Write("\r\n\t\t\t\t<div id=\"contentheader\">\r\n\t\t\t\t\t<table>\r\n\t\t \t\t\t\t<tr>\r\n\t\t\t\t\t\t\t<td>");Line 140: Line 141: #line 17 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 142: parameterContainer.Controls[0].RenderControl(__output);Line 143: Line 144: #line defaultLine 145: #line hiddenLine 146: __output.Write("\r\n\t\t\t\t\t\t\t</td>\r\n\t\t\t\t\t\t\t<td width=\"75%\" align=\"right\" valign=\"top\"><div id=\"Signed" +Line 147: "In\">Logged in as: ");Line 148: Line 149: #line 19 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 150: __output.Write(username);Line 151: Line 152: #line defaultLine 153: #line hiddenLine 154: __output.Write("<br>Position: ");Line 155: Line 156: #line 19 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 157: __output.Write(positionId);Line 158: Line 159: #line defaultLine 160: #line hiddenLine 161: this.WriteUTF8ResourceString(__output, 0, 553, true);Line 162: }Line 163: Line 164: private void __BuildControlTree(System.Web.UI.Control __ctrl) {Line 165: Line 166: #line 1 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 167: this.__BuildControlfrmMain();Line 168: Line 169: #line defaultLine 170: #line hiddenLine 171: System.Web.UI.IParserAccessor __parser = ((System.Web.UI.IParserAccessor)(__ctrl));Line 172: Line 173: #line 1 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 174: __parser.AddParsedSubObject(this.frmMain);Line 175: Line 176: #line defaultLine 177: #line hiddenLine 178: __ctrl.SetRenderMethodDelegate(new System.Web.UI.RenderMethod(this.__Render__control1 ));Line 179: }Line 180: Line 181: private void __Render__control1(System.Web.UI.HtmlTextWriter __output, System.Web.UI.Control parameterContainer) {Line 182: __output.Write("\r\n<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\" >\r\n<HTML>\r\n\t<HEAD" +Line 183: ">\r\n\t\t<title>\r\n\t\t\t");Line 184: Line 185: #line 7 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 186: __output.Write(ConfigurationSettings.AppSettings["ReplicatedTitle"]);Line 187: Line 188: #line defaultLine 189: #line hiddenLine 190: __output.Write(" - Project Coordinator Home\r\n\t\t</title>\r\n\t\t<link media=\"screen\" href=\"resources/s" +Line 191: "tyle/PM.css\" type=\"text/css\" rel=\"stylesheet\">\r\n\t</HEAD>\r\n\t<body>\r\n\t\t<div id=\"fr" +Line 192: "ame\">\r\n\t\t\t");Line 193: Line 194: #line 13 "d:\hosting\jstrockbine77\wwwroot\ProjectManager.A pp\ProjectHome.aspx"Line 195: parameterContainer.Controls[0].RenderControl(__output);Line 196: Line 197: #line defaultLine 198: #line hiddenLine 199: __output.Write("\r\n\t\t</div>\r\n\t\t<!-- allows div frame to extend for old browsers -->\r\n\t\t<br clear=\"" +Line 200: "all\">\r\n\t</body>\r\n</HTML>\r\n\r\n");Line 201: }Line 202: Line 203: protected override void FrameworkInitialize() {Line 204: SetStringResourcePointer(ASP.projecthome_aspx.__st ringResource, 553);Line 205: this.__BuildControlTree(this);Line 206: this.FileDependencies = ASP.projecthome_aspx.__fileDependencies;Line 207: this.EnableViewStateMac = true;Line 208: this.Request.ValidateInput();Line 209: }Line 210: Line 211: public override int GetTypeHashCode() {Line 212: return 302415736;Line 213: }Line 214: }Line 215: }Line 216:

function OnToggleTOCLevel1(){ var elemSrc = window.event.srcElement; var elemLevel2 = document.all(elemSrc.level2ID); if (elemLevel2.style.display == 'none') { elemLevel2.style.display = ''; if (elemSrc.usesGlyph == '1') elemSrc.innerHTML = '6'; } else { elemLevel2.style.display = 'none'; if (elemSrc.usesGlyph == '1') elemSrc.innerHTML = '4'; }}
jstrockbine is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
     
Old 12-24-2006, 10:25 AM Re: Exists but not recognizing...
vivekar's Avatar
Webmaster Talker

Posts: 537
I am confused at the code dump.

Have you declared the variable username and positionid in the code

protected string username;
protected string positionid;

If not, add it and try compiling this code.

__________________
| Submit URL at All the Websites Directory
| Get Certified in Web Design
vivekar is offline
Reply With Quote
View Public Profile Visit vivekar's homepage!
 
Reply     « Reply to Exists but not recognizing...
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.16718 seconds with 13 queries