Showing posts with label message. Show all posts
Showing posts with label message. Show all posts

Wednesday, March 28, 2012

The compiler failed with error code 128

I have a C#.NET application running perfectly on my notebook but when I copy it up to our development server I get the above error message. The Compiler Output has "C:\Program Files\SAP\ITS\6.20\WGATE\traces> ...

SAP\ITS is an ISAPI Filter that runs to provide Web access to SAP. My application not using SAP for anything.

We found one Weblog that mentioned a rogue ISAPI filter and moving it's priority below ASP.NET fixed their problem. We tried moving the ITS ISAPI filter below ASP.NET, rebooted the machine and it worked. We don't know if the reboot fixed it or the moving of the ISAPI filter.

After I made a change to the C# application and re-copied the .DLL to the server it died again with the same message.Check out this discussion on GotDotNet:

http://www.gotdotnet.com/community/messageboard/Thread.aspx?id=139158&Page=1

Monday, March 26, 2012

The compiler failed with error code 2000

I keep getting this message "The compiler failed with error code 2000"
when pressing PF5 to run Debug. This is not a compile error, it gets
past the compile. I get this when it tries to load up my web
application. Once I get this message, I then rebuild the solution and
then I can press PF5 and run debug just fine. It started out
happening just once in a while, now it happens every other time I try
and run in Debug mode. I have tried several things, "Rebuild
Solution", Get out of visual Studio and then come back in, and I have
also tried to delete
C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tempo rary ASP.NET Files.
All of these options works once, then I have to do it all over again.

Anybody have a more permanent solution?Hi

This error indicates various initialization failures. Reinstall Visual Studio.

Ravikanth[MVP]

"Russ" wrote:

> I keep getting this message "The compiler failed with error code 2000"
> when pressing PF5 to run Debug. This is not a compile error, it gets
> past the compile. I get this when it tries to load up my web
> application. Once I get this message, I then rebuild the solution and
> then I can press PF5 and run debug just fine. It started out
> happening just once in a while, now it happens every other time I try
> and run in Debug mode. I have tried several things, "Rebuild
> Solution", Get out of visual Studio and then come back in, and I have
> also tried to delete
> C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tempo rary ASP.NET Files.
> All of these options works once, then I have to do it all over again.
>
> Anybody have a more permanent solution?
OK, first I reinstalled the framework 1.1 - It still happened.

I then "Reinstalled Visual Studios" (without uninstalling it first)-
It still happened.

Then I removed/uninstalled Visual Studios and then re-installed it. -
It is still happening.

Here is additional information ...

vbc : Command line error BC2017 : could not find library
'c:\windows\microsoft.net\framework\v1.1.4322\temp orary asp.net
files\peb.intranet.2.0\c9e073a6\c1381c80\assembly\ dl2\2820a9d4\20469c4b_7422c401\interop.combiztalks uspendedqueue.dll'

From what I can tell it's looking for a directory that's not on my PC.
When looking at my hard drive I have the following path...

'c:\windows\microsoft.net\framework\v1.1.4322\temp orary asp.net
files\peb.intranet.2.0\c9e073a6\c1381c80\assembly\ dl2\

after the "d12" directory there is no 2820a9d4 directory. There are
10 other directories but not the one Visual Studio is looking for.

If I do a "Re-build Solution", then I can compile in debug again, or
if I get out of Visual studio, come back in, then it will work. I
have even deleted the "temporary asp.net" path.

Any other ideas of what maybe causing this?

"Ravikanth[MVP]" <RavikanthMVP@dotnet.itags.org.discussions.microsoft.com> wrote in message news:<7294B7D8-7DDC-48FE-AA17-E3909F8C4FDD@dotnet.itags.org.microsoft.com>...
> Hi
> This error indicates various initialization failures. Reinstall Visual Studio.
> Ravikanth[MVP]
>
> "Russ" wrote:
> > I keep getting this message "The compiler failed with error code 2000"
> > when pressing PF5 to run Debug. This is not a compile error, it gets
> > past the compile. I get this when it tries to load up my web
> > application. Once I get this message, I then rebuild the solution and
> > then I can press PF5 and run debug just fine. It started out
> > happening just once in a while, now it happens every other time I try
> > and run in Debug mode. I have tried several things, "Rebuild
> > Solution", Get out of visual Studio and then come back in, and I have
> > also tried to delete
> > C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tempo rary ASP.NET Files.
> > All of these options works once, then I have to do it all over again.
> > Anybody have a more permanent solution?
> > "Russ" wrote:
> > > I keep getting this message "The compiler failed with error code 2000"
> > > when pressing PF5 to run Debug. This is not a compile error, it gets
> > > past the compile. I get this when it tries to load up my web
> > > application. Once I get this message, I then rebuild the solution and
> > > then I can press PF5 and run debug just fine. It started out
> > > happening just once in a while, now it happens every other time I try
> > > and run in Debug mode. I have tried several things, "Rebuild
> > > Solution", Get out of visual Studio and then come back in, and I have
> > > also tried to delete
> > > C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tempo rary ASP.NET Files.
> > > All of these options works once, then I have to do it all over again.
> > > > > Anybody have a more permanent solution?
>
We also know about this problem and a temporary solution (workaround) that works.
Annoying but faster than closing visual studio. When you compile the solution,
and then you get this error when you run it...try changing the mode from Debug to
Release and back to Debug or toggle it to the opposite. From there, try running
the application again. It should go away.

We found that it has something to do with Component Services and
Transactions...<mumbles
Mythran

The compiler failed with error code 2000

I keep getting this message "The compiler failed with error code 2000"
when pressing PF5 to run Debug. This is not a compile error, it gets
past the compile. I get this when it tries to load up my web
application. Once I get this message, I then rebuild the solution and
then I can press PF5 and run debug just fine. It started out
happening just once in a while, now it happens every other time I try
and run in Debug mode. I have tried several things, "Rebuild
Solution", Get out of visual Studio and then come back in, and I have
also tried to delete
C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Temporary ASP.NET Files.
All of these options works once, then I have to do it all over again.
Anybody have a more permanent solution?Hi
This error indicates various initialization failures. Reinstall Visual Studi
o.
Ravikanth[MVP]
"Russ" wrote:

> I keep getting this message "The compiler failed with error code 2000"
> when pressing PF5 to run Debug. This is not a compile error, it gets
> past the compile. I get this when it tries to load up my web
> application. Once I get this message, I then rebuild the solution and
> then I can press PF5 and run debug just fine. It started out
> happening just once in a while, now it happens every other time I try
> and run in Debug mode. I have tried several things, "Rebuild
> Solution", Get out of visual Studio and then come back in, and I have
> also tried to delete
> C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Temporary ASP.NET Files.
> All of these options works once, then I have to do it all over again.
>
> Anybody have a more permanent solution?
>
OK, first I reinstalled the framework 1.1 - It still happened.
I then "Reinstalled Visual Studios" (without uninstalling it first)-
It still happened.
Then I removed/uninstalled Visual Studios and then re-installed it. -
It is still happening.
Here is additional information ...
vbc : Command line error BC2017 : could not find library
'c:\windows\microsoft.net\framework\v1.1.4322\temporary asp.net
files\peb.intranet.2. 0\c9e073a6\c1381c80\assembly\dl2\2820a9d
4\20469c4b_7422
c401\interop.combiztalksuspendedqueue.dll'
From what I can tell it's looking for a directory that's not on my PC.
When looking at my hard drive I have the following path...
'c:\windows\microsoft.net\framework\v1.1.4322\temporary asp.net
files\peb.intranet.2.0\c9e073a6\c1381c80\assembly\dl2\
after the "d12" directory there is no 2820a9d4 directory. There are
10 other directories but not the one Visual Studio is looking for.
If I do a "Re-build Solution", then I can compile in debug again, or
if I get out of Visual studio, come back in, then it will work. I
have even deleted the "temporary asp.net" path.
Any other ideas of what maybe causing this?
"Ravikanth[MVP]" <RavikanthMVP@dotnet.itags.org.discussions.microsoft.com> wrote in message news:<7294B7D8-7DDC-4
8FE-AA17-E3909F8C4FDD@dotnet.itags.org.microsoft.com>...
> Hi
> This error indicates various initialization failures. Reinstall Visual Stu
dio.
> Ravikanth[MVP]
>
> "Russ" wrote:
>

We also know about this problem and a temporary solution (workaround) that w
orks.
Annoying but faster than closing visual studio. When you compile the soluti
on,
and then you get this error when you run it...try changing the mode from Deb
ug to
Release and back to Debug or toggle it to the opposite. From there, try run
ning
the application again. It should go away.
We found that it has something to do with Component Services and
Transactions...<mumbles>
Mythran

Saturday, March 24, 2012

The data at the root level is invalid. Line 1, position 1

Hi there,
I got this message ("The data at the root level is invalid. Line 1, position
1.") when I moved the application from my workstation to Windows 2003 web
server. But the wired thing the whole application works fine on my
workstation which running Windows XP prof sp 2 edition.
Please help me out
Thanks
AlanOn Fri, 05 Aug 2005 12:24:33 -0400, Alan Wang wrote:

> Hi there,
> I got this message ("The data at the root level is invalid. Line 1, positi
on
> 1.") when I moved the application from my workstation to Windows 2003 web
> server. But the wired thing the whole application works fine on my
> workstation which running Windows XP prof sp 2 edition.
> Please help me out
> Thanks
> Alan
If ds is your DataSet, you can refer to the tables by name as in
ds.Tables("yourTableName")

The data at the root level is invalid. Line 1, position 1

Hi there,

I got this message ("The data at the root level is invalid. Line 1, position
1.") when I moved the application from my workstation to Windows 2003 web
server. But the wired thing the whole application works fine on my
workstation which running Windows xp prof sp 2 edition.

Please help me out

Thanks

AlanOn Fri, 05 Aug 2005 12:24:33 -0400, Alan Wang wrote:

> Hi there,
> I got this message ("The data at the root level is invalid. Line 1, position
> 1.") when I moved the application from my workstation to Windows 2003 web
> server. But the wired thing the whole application works fine on my
> workstation which running Windows xp prof sp 2 edition.
> Please help me out
> Thanks
> Alan
If ds is your DataSet, you can refer to the tables by name as in
ds.Tables("yourTableName")

Thursday, March 22, 2012

The GridView 'GridView1' fired event Sorting which wasn't handled

Hi,
I get this error message when sorting a gridview:
The GridView 'GridView1' fired event Sorting which wasn't handled
What do I need to do?
Thanks!Hi,
you have AllowSorting="true" set for the GridView and therefore you need to
have event handler for its Sorting event
<asp:GridView AllowSorting=true ID="GridView1" runat="server"
OnSorting="GridView1_Sorting">
..
</asp:GridView>
protected void GridView1_Sorting(object sender, GridViewSortEventArgs e)
{
//...
}
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU
http://blogs.aspadvice.com/joteke
"Arjen" <boah123@.hotmail.com> wrote in message
news:ddsgue$nbj$1@.news1.zwoll1.ov.home.nl...
> Hi,
> I get this error message when sorting a gridview:
> The GridView 'GridView1' fired event Sorting which wasn't handled
> What do I need to do?
> Thanks!
>
I tried, I don't get it to work.
I don't know what to add inside the GridView1_Sorting method.
I'm using the gridview with templatefields.
Can you help me?
Thanks!
"Teemu Keiski" <joteke@.aspalliance.com> schreef in bericht
news:epu6hdooFHA.1372@.TK2MSFTNGP10.phx.gbl...
> Hi,
> you have AllowSorting="true" set for the GridView and therefore you need
> to
> have event handler for its Sorting event
> <asp:GridView AllowSorting=true ID="GridView1" runat="server"
> OnSorting="GridView1_Sorting">
> ...
> </asp:GridView>
>
> protected void GridView1_Sorting(object sender, GridViewSortEventArgs e)
> {
> //...
> }
>
> --
> Teemu Keiski
> ASP.NET MVP, AspInsider
> Finland, EU
> http://blogs.aspadvice.com/joteke
> "Arjen" <boah123@.hotmail.com> wrote in message
> news:ddsgue$nbj$1@.news1.zwoll1.ov.home.nl...
>

The GridView GridView1 fired event Sorting which wasnt handled

Hi,

I get this error message when sorting a gridview:
The GridView 'GridView1' fired event Sorting which wasn't handled

What do I need to do?

Thanks!Hi,

you have AllowSorting="true" set for the GridView and therefore you need to
have event handler for its Sorting event

<asp:GridView AllowSorting=true ID="GridView1" runat="server"
OnSorting="GridView1_Sorting">
...
</asp:GridView
protected void GridView1_Sorting(object sender, GridViewSortEventArgs e)
{
//...
}

--
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU
http://blogs.aspadvice.com/joteke

"Arjen" <boah123@.hotmail.com> wrote in message
news:ddsgue$nbj$1@.news1.zwoll1.ov.home.nl...
> Hi,
> I get this error message when sorting a gridview:
> The GridView 'GridView1' fired event Sorting which wasn't handled
> What do I need to do?
> Thanks!
I tried, I don't get it to work.
I don't know what to add inside the GridView1_Sorting method.

I'm using the gridview with templatefields.

Can you help me?

Thanks!

"Teemu Keiski" <joteke@.aspalliance.com> schreef in bericht
news:epu6hdooFHA.1372@.TK2MSFTNGP10.phx.gbl...
> Hi,
> you have AllowSorting="true" set for the GridView and therefore you need
> to
> have event handler for its Sorting event
> <asp:GridView AllowSorting=true ID="GridView1" runat="server"
> OnSorting="GridView1_Sorting">
> ...
> </asp:GridView>
>
> protected void GridView1_Sorting(object sender, GridViewSortEventArgs e)
> {
> //...
> }
>
> --
> Teemu Keiski
> ASP.NET MVP, AspInsider
> Finland, EU
> http://blogs.aspadvice.com/joteke
> "Arjen" <boah123@.hotmail.com> wrote in message
> news:ddsgue$nbj$1@.news1.zwoll1.ov.home.nl...
>> Hi,
>>
>> I get this error message when sorting a gridview:
>> The GridView 'GridView1' fired event Sorting which wasn't handled
>>
>> What do I need to do?
>>
>> Thanks!
>>
>>

Tuesday, March 13, 2012

The HTTP verb POST used to access path /WebSite11/HTMLPage.htm is not allowed.]

I got that error message when I clicked a Link Button that had it's PostBackUrl set to HTMLPage.htm.

Any insights?

Thanks,

Dave

Not sure about the error, but if you want to post the data to a normal html-page. Why not use a simple html-submit-button?

<input type="submit" value="Post My Data!" />

Whouldn't that work for you?

The login failed. Login failed for user

Hi

I am trying to capture and display a user-friendly message when my database/server is offline

In order to do the above task, I have taken my database offline and put in the following code to log and show an error has occurred.

PLEASE bear in mind the database is offline and that's what I am trying to test for

C# for RequestDetails.aspx.cs

using System.IO;

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;

publicpartialclass_Default : System.Web.UI.Page

{

protectedvoid Page_Load(object sender,EventArgs e)

{

try

{

Console.WriteLine("Executing the try statement.");

//throw new SqlException();

}

catch ( System.Data.SqlClient.SqlException test)

{

Console.WriteLine("{0} Caught exception #1.", test);

Exception objErr = Server.GetLastError().GetBaseException();

//string err = "Error Caught in Application_Error event\n" +

// "Error in: " + Request.Url.ToString() +

// "\nError Message:" + objErr.Message.ToString() +

// "\nStack Trace:" + objErr.StackTrace.ToString();

//EventLog.WriteEntry("Sample_WebApp", err, EventLogEntryType.Error);

////Tools.Log("sadsadsadas", err);

Response.Write("error" + test.Message +"<br>");

Tools.Log("log test ", test); //Logs error

Tools.SendEmail("Email test ", test); /Emails Error

}

}

When I view the page I get

Exception Details:System.Data.SqlClient.SqlException: Cannot open database "CRM" requested by the login. The login failed.
Login failed for user 'ABCDXXXSYSTEMS\ysmith'.

Can anyone tell me how to trap and action database/server offline errors please? I know I am missing a big part of a puzzle

Thanks in advance

Try the following:

protectedvoid Page_Load(object sender,EventArgs e)

{

try

{

SqlConnection Cn =newSqlConnection("connection string here");

Cn.Open();

}

catch (SqlException Ex)

{

Response.Write (

"Database is unavailable.");

}

}


What I would like to do is

publicvoid Page_Error(object sender,EventArgs e)

{

Exception objError = Server.GetLastError().GetBaseException();string strError ="<b>Error Has Been Caught in Page_Error event</b><hr><br>" +"<br><b>Error in: </b>" + Request.Url.ToString() +"<br><b>Error Message: </b>" + objError.Message.ToString() +"<br><b>Stack Trace:</b><br>" +

objError.StackTrace.ToString();

Session["ErrorMessage"] ="Cannot open CRM";

Server.ClearError();

Response.Redirect("error.aspx?ErrorMessage" + Session["ErrorMessage"].ToString());

}

in the error page display the Session["ErrorMessage"]

protectedvoid Page_Load(object sender,EventArgs e)

{

ErrorLabel.Text = Session["ErrorMessage"].ToString();}}

}

But I get error System.NullReferenceException: Object reference not set to an instance of an object.

at line:

ErrorLabel.Text = Session["ErrorMessage"].ToString();}}

thanks in advance


Try to check if session isnt null before your set the text of the ErrorLabel control.

maybe when your page loads, there isnt any error, meanwhile you are identifying the session in the page_error which didnt get executed.

protectedvoid Page_Load(object sender,EventArgs e)

{

if(Session["ErrorMessage"] != null)

{

ErrorLabel.Text = Session["ErrorMessage"].ToString();

}

}

HC


Try opening a connection to the database which would indicate connectivity or not.

Thanks guys

I did try the suggestions without much joy. The session["ErrorMessage"] = ""

Also it would be so much easier if I could read the status code.

Thanks in advance