VS 2010 Compiler Error Message BC30205 / End Of Statement Expected
Sep 15, 2011
I am new to asp... I tried to the below script referring to a tutorial which gives the error Compiler Error Message: BC30205: End of statement expected.
At this file (Global.asax) and you can check my website: [URL]......
Compiler Error Message: BC30205: End of statement expected.
Source Error:
Line 16: Line 17: Function GetParentDir() As String Line 18: Dim PD String = Server.MapPath("db") Line 19: PD = System.IO.Directory.GetParent(PD).ToString & "db" Line 20: Return PD
Using the exact same text.aspx file containing the above code he gets the error:
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: CS1002: ; expected
Source Error: Line 3: <center> Line 4: <h2>Hello</h2> Line 5: <p><%Response.Write(now())%></p> Line 6: </center> Line 7: </body>
I am using windows 7, my application is working fine in visual studio but when i host it and browse it through my browser getting the following error. Sometime back it worked fine but recently it started giving this error. Server Error in '/InfraICHR' 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: BC2000: compiler initialization
I created a web application using visual studio 2010 / MVC2 / MSSQL 2008 and it runs fine in my laptop. However when I run the application in the hosting provider it shows the error message below:
Compiler Error Message: CS0308
The hosting provider is [URL] and the link to my web application is [URL] I would like to know how to solve this issue? If anyone know PLEASE let me know how to troubleshoot / fix this issue. Also in case the problem is on the hosting provider, let me know if you know of a free or very affordable hosting provider with support for MVC 2 and MSSQL 2008.
I am a recent convert to ASP and a fairly total n00b, which means that though I've worked with web technologies for all my life, I have no idea how ASP handles them and I'm learning step by step so I beg for some patience as my many questions may be trivial.
For example, I've followed a couple of online tutorials on creating basic authentication via web.config, however I have run into some trouble. Here is my setup:
[Code]....
and some HTML:
[Code]....
However, after compiling, the browser tells me this:
Description: Error compiling a resource required to service this request. Review your source file and modify it to fix this error.
Compiler Error Message: CS1061: Type `ASP.views_login_index_aspx' does not contain a definition for `ProcessLogin' and no extension method `ProcessLogin' of type `ASP.views_login_index_aspx' could be found (are you missing a using directive or an assembly reference?)
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: CVT1106: cannot write to file
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: BC30451: Name 'SendMail' is not declared.
I have a ASP.NET (C#) web page in which I want to enumerate a dictionary in a code render block:
<% foreach (Dictionary<string, string> record in parsedData) { %> <div>...Some HTML Code...</div> <% } %>
But I get an error like:
Compiler Error Message: CS0246: The type or namespace name 'Dictionary' could not be found (are you missing a using directive or an assembly reference?)
How do I import System.Collections.Generic into the page itself? Here is my page directive:
Compilation Error Description: An error occurred during the compilation of a resource required to service this request. review the following specific error details and modify your source code appropriately. Compiler Error Message: BC30451: Name 'SubIds' is not declared.Source Error:
Line 41: 'End If Line 42: Dim dv As DataView Line 43: SubIds As String = "", Line 44: SelectedDetails As String() = Session("SubClassIds").ToString().Split(",") Line 45: divShowClassList.Visible = True
I just upgraded my blog [URL] to BlogEngine 1.6.1 (from 1.6.0) in order to use the reCaptcha extension. I upgraded my local code from 1.6.0 to 1.6.1, then published via FTP through WebMatrix. After the upgrade, I am getting this error:
Compiler Error Message: CS0433: The type 'Resources.labels' exists in both 'c:windowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files oot9fd92f8745a2ba06assemblydl3a64307f6f14811b8_0291cb01App_GlobalResources.DLL' and 'c:windowsMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Files oot9fd92f8745a2ba06App_GlobalResources.md7pit6m.dll'
The source file and line number where it breaks varies, but it is always the same basic message. What differs is the "md7pt66m" section of the App_GlobalResources.md7pit6m.dll (the second file path in the error message). I was able to fix the error locally by deleting the Temporary ASP.NET Files, but I can't do this on my hosting server (GoDaddy). Is there something I can do to fix the error? Based on suggestions from the codeplex discussion page, I have edited web.config file in order to cycle the app pool, and renamed BlogEngine.Core.dll to BlogEngine.Core2.dll and then back in order to restart the blog. I have also added batch="false" to the <compilation> tag in web.config (based on this post). I have turned custom errors off, so you can see the error on my site now.
I upgraded my web application from visual studio 2003 to 2008. When I want to create a report in visual studio 2008 and receiving this error at runtime. I am able to compile but when runnning thats when I am getting this error. How can I solve this problem?
Server Error in '/IRPSDEV' 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: CS0433: The type 'CrystalDecisions.Web.CrystalReportViewer' exists in both
'c:WINDOWSassemblyGAC_MSILCrystalDecisions.Web10.5.3700.0__692fbea5521e1304CrystalDecisions.Web.dll' and 'c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Filesirpsdev9e97e0a994a2ecdassemblydl3151eb571�0df56e1_6064c201CrystalDecisions.Web.DLL'
Source Error:
[Code]....
Line 161: Line 162: [System.Diagnostics.DebuggerNonUserCodeAttribute()] Line 163: private global::CrystalDecisions.Web.CrystalReportViewer @__BuildControlCrystalReportViewer1() { Line 164: global::CrystalDecisions.Web.CrystalReportViewer @__ctrl; Line 165:
Source File: c:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET Filesirpsdev9e97e0a994a2ecdApp_Web_customsapprovedcalimsreport.aspx.cdcab7d2.qc0hdu8q.0.cs Line: 163 Show Detailed Compiler Output:
CS0103: The name 'lblRegion' does not exist in the current context
Source Error:
[Code]....
Line 31: {Line 32: Line 33: lblRegion.Text = dt.Rows[0]["RegionName"].ToString();Line 34: lblCountry.Text = dt.Rows[0]["CountryName"].ToString();Line 35: lblCountryCode.Text = dt.Rows[0]["CountryCode"].ToString();
this is source code: using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Web.UI.HtmlControls; using System.Net; using System.Xml; public partial class CSharp : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { //Get IP Address string ipaddress; ipaddress = Request.ServerVariables["HTTP_X_FORWARDED_FOR"]; if (ipaddress == "" || ipaddress == null) ipaddress = Request.ServerVariables["REMOTE_ADDR"]; DataTable dt = GetLocation(ipaddress); if (dt != null) { if (dt.Rows.Count > 0) { lblCity.Text = dt.Rows[0]["City"].ToString(); lblRegion.Text = dt.Rows[0]["RegionName"].ToString(); lblCountry.Text = dt.Rows[0]["CountryName"].ToString(); lblCountryCode.Text = dt.Rows[0]["CountryCode"].ToString(); } else { } } } private DataTable GetLocation(string ipaddress) { //Create a WebRequest WebRequest rssReq = WebRequest.Create("[URL]xml/" + ipaddress); //Create a Proxy WebProxy px = new WebProxy("[URL]+ ipaddress, true); //Assign the proxy to the WebRequest rssReq.Proxy = px; //Set the timeout in Seconds for the WebRequest rssReq.Timeout = 2000; try { //Get the WebResponse WebResponse rep = rssReq.GetResponse(); //Read the Response in a XMLTextReader XmlTextReader xtr = new XmlTextReader(rep.GetResponseStream()); //Create a new DataSet DataSet ds = new DataSet(); //Read the Response into the DataSet ds.ReadXml(xtr); return ds.Tables[0]; } catch { return null; } } }
I usually only write in ASP, so I am not very familiar with this script. Can anyone tell me how to how to request a querystring so I can use it to pull the image location. Like this.
I added a web reference to a web service to my web project. I can add an instance of the web service in my code and everything appears to work fine. But if I try to debug my code I get a complie error stating that the Type is not defined. What am I doing wrong?
Description: An error occurred during the compilation of a resource required to service this request. review the following specific error details and modify your source code appropriately.
Compiler Error Message: BC30002: Type 'WSQSPExport.OrderImport' is not defined.
Source Error:
[Code]....
Line 336: Dim boolResult As Boolean = True Line 337: Dim strException As String Line 338: Dim objQSPExport As New WSQSPExport.OrderImport Line 339: Dim reader As XmlReader Line 340: Dim sr As System.IO.StreamReader Source File: F:WebsxxxFarmsxxxWebApp_Codecls_ExportQSP.vb Line: 338
I'm accessing a Masterpage property from a regular page by doing the following:
[Code]....
I get the following error message:
Compiler Error Message: CS0246: The type or namespace name 'SecondMasterPage' could not be found (are you missing a using directive or an assembly reference?)
My base class file is a file called BaseClass.cs in my App_Code directory. Other functions in there work without errors. Why?
I already published my client's site and i received problem during loading page.
here's the 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: CS1501: No overload for method 'UpdateBookInfo' takes '5' arguments
Source Error:
Line 33: //Update Book Info Line 34: Book BookProcess = new Book(); Line 35: BookProcess.UpdateBookInfo(SKU, Title, Description, Price, Status); Line 36: Line 37: //Update Book Picture
I am using an application from a book for a shopping application , to adapt for my own learning, but there seems to be a problem with the shopping cart page. This is a section I have not changed as there is no need to but there is an error. In the code behind the only thing new is the namespace:
namespace OIClothing { public partial class Cart : System.Web.UI.Page { ShoppingCart cart; // it doesn't like this, giving the debug message the type or namespace 'Shopping Cart" could not be found protected void Page_Load(object sender, EventArgs e) { CheckTimeStamps(); if (Session["cart"] == null) { cart = new ShoppingCart(); Session["cart"] = cart; } else { cart = (ShoppingCart)Session["cart"]; } GridView1.DataSource = cart.GetItems(); if (!IsPostBack) GridView1.DataBind(); btnCheckOut.Enabled = (cart.Count > 0); } protected void GridView1_RowDeleting(object sender, GridViewDeleteEventArgs e) { cart.DeleteItem(e.RowIndex); GridView1.DataBind(); }
but when running the page, this error is given: CS1061: 'ASP.cart_aspx' does not contain a definition for 'GridView1_RowDeleting' and no extension method 'GridView1_RowDeleting' accepting a first argument of type 'ASP.cart_aspx' could be found (are you missing a using directive or an assembly reference?)