my page calls a stored procedure......
but it does not work.....
<%@.PageLanguage="C#"MasterPageFile="~/Masterhowit.master"Title="Untitled Page" %><%@.ImportNamespace="System.Net.Mail" %>
<%@.ImportNamespace="System.Data.SqlClient" %>
<scriptrunat="server">
protectedvoid Button1_Click(object sender,EventArgs e){
//.....sql insert statement for stored procedure...make active?
string numberintextbox = TextBox1.Text;
string yippyaddress = Request.UserHostAddress.ToString();
string dateandtime = DateTime.Now.ToString();
SqlDataSource Datast1000 = new SqlDataSource();
Datast1000.ConnectionString = ConfigurationManager.ConnectionStrings["ConnectionStringtodatast1000"].ToString();
Datast1000.InsertCommandType = SqlDataSourceCommandType.StoredProcedure;
Datast1000.InsertCommand = "givemeinserting";
Datast1000.InsertParameters.Add("@.mobiles", numberintextbox);
Datast1000.InsertParameters.Add("@.ipaddress", yippyaddress);
The page collects mobile tele numbers......ipaddress.....and DateTimeStamp
well should.
The stored procedure works fine when executed from the database explorer and asks for the parameters all ok.
The connection string is fine and matches the web config......all compiles ok but at run time makes the berp noise
then my... if else.... throws exception to say no database entry made.
//--kickout---for no uploadint rowsAffected = 0;
try
{
rowsAffected = Datast1000.Insert();
}
catch (Exception ex){
// this error page says sorry error and sends message to admin about failure
Server.Transfer("erroratgiveme.aspx");}
finally
{
Datast1000 =null;}
if (rowsAffected != 1){
// this page says sorry there has been an error loading..try again
Server.Transfer("erroratgiveloading.aspx");}
else
{
//happy days...go to giveme
Server.Transfer("giveme.aspx");}
----------------------
I feel the code is fine because I have played with it for hours.....made basic insert statements etc.
Now this all worked fine two months ago until I tried to build a second page with insert statements then
nada.
Left it whilst I learned how to use microsoft sql server management express. Now tried for days to find problem
with no luck......
Should anyone from up high be available i would be very greatfull
Does anyone know what this means below
-------------------
The thread 0xb58 has exited with code 0 (0x0).
A first chance exception of type 'System.Data.SqlClient.SqlException' occurred in System.Web.dll
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\st1000april7\c09871d0\14ed6cf9\App_Web_9nwdvyfr.dll', Symbols loaded.
A first chance exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll
An exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll but was not handled in user code
The program '[2652] WebDev.WebServer.EXE: Managed' has exited with code 0 (0x0).
Try to delete the Temporary files under the directory
'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files
and rebuild and try the application
|||Try to delete the Temporary files under the directory
'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files
and rebuild and try the application
Delete all the folder under the specified path
|||trying...trying..hold on|||
App_global.asax.compiled
App_global.asax.eo21_x31.0.cs
App_WebReferances.3-2oi4
App_Webreferances.compiled
hash.web
any of these?
Am i looking in the right place......did search for
TemporaryASP.NET Files
regards rich
|||right found it and deleted all objects within the folder.....rerun application...still not doing
it...however I think you are close ......anything else to do?
|||What error you are getting this time? Is it same please copy & paste the stack trace
|||Well thats the problem.
there is no error.
asp thinks its done the job..... its just that no data is going into the db.
And there are no tipos......spent hours on that...
remember stored procedure works fine in database explorer.
Its as if my page data is all running fine its just not arriving at the database door.
I thought the page my have a corruption onit so made new page and deleted old one..still no good.
made an admin page and put onit a from view and gridview......all working fine at runtime and inserting data!
Also have form view on the fault page which is working fine.
its a no brainer
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\mscorlib\2.0.0.0__b77a5c561934e089\mscorlib.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\WebDev.WebServer.EXE', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\WebDev.WebHost\8.0.0.0__b03f5f7f11d50a3a\WebDev.WebHost.dll', No symbols loaded.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Windows.Forms\2.0.0.0__b77a5c561934e089\System.Windows.Forms.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System\2.0.0.0__b77a5c561934e089\System.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Drawing\2.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
Warning: Cannot debug script code. Script debugging is disabled for the application you are debugging. Please uncheck the 'Disable script debugging' option on the Internet Options dialog box (Advanced page) for Internet Explorer and restart the process.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\System.Web\2.0.0.0__b03f5f7f11d50a3a\System.Web.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Configuration\2.0.0.0__b03f5f7f11d50a3a\System.Configuration.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Xml\2.0.0.0__b77a5c561934e089\System.Xml.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.RegularExpressions\2.0.0.0__b03f5f7f11d50a3a\System.Web.RegularExpressions.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\System.Data\2.0.0.0__b77a5c561934e089\System.Data.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\System.Transactions\2.0.0.0__b77a5c561934e089\System.Transactions.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\System.EnterpriseServices\2.0.0.0__b03f5f7f11d50a3a\System.EnterpriseServices.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\Microsoft.JScript\8.0.0.0__b03f5f7f11d50a3a\Microsoft.JScript.dll', No symbols loaded.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\st1000april7\c09871d0\14ed6cf9\App_WebReferences.r9lj_2qs.dll', Symbols loaded.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Services\2.0.0.0__b03f5f7f11d50a3a\System.Web.Services.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\st1000april7\c09871d0\14ed6cf9\App_global.asax.lyflx3jz.dll', Symbols loaded.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Mobile\2.0.0.0__b03f5f7f11d50a3a\System.Web.Mobile.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\st1000april7\c09871d0\14ed6cf9\App_Web_zbstgaax.dll', Symbols loaded.
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\st1000april7\c09871d0\14ed6cf9\App_Web_masterhowit.master.cdcab7d2.nufeebfc.dll', Symbols loaded.
A first chance exception of type 'System.Data.SqlClient.SqlException' occurred in System.Web.dll
A first chance exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll
An exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll but was not handled in user code
The thread 0x534 has exited with code 0 (0x0).
A first chance exception of type 'System.Data.SqlClient.SqlException' occurred in System.Web.dll
A first chance exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll
An exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll but was not handled in user code
'WebDev.WebServer.EXE' (Managed): Loaded 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\st1000april7\c09871d0\14ed6cf9\App_Web_2itmrd10.dll', Symbols loaded.
The program '[780] WebDev.WebServer.EXE: Managed' has exited with code 0 (0x0).
|||
Its not looking good we can try one more thing Uninstall the
aspnet_regiis.exe -ua
and then reinstall using
aspnet_regiis.exe -i
Make sure you are in C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\ directory before u run the commands. Send me the Code Behind as Well
I appriciate you patience![]()
mmm dont seem to have that file aspnet_regiis.exe -ua
I have four aspnet_regiis.exe files.......one of which is the 2.0.50727
search did not find ...aspnet_regiis.exe -ua
......so what is worst case sinario...delete and reload web dev
this all worked with sql insert statement in feb but suddenly lost the plot
|||No the aspnet_regiis.exe is a file and
aspnet_regiis.exe -ua is command line parameters you need to supply when u execute from command line
and after that again from the command prompt run aspne_regiis.exe -i
|||
derr
|||
? what was that
need help to run that.....got a mate who can help
but cant see him till friday.
going to have to put this on hold I think till then....going to mark post as answer for you
thanks so much for help.....ill post back here when Ive done it.
again thanks so much
rich
|||don't worry we need to resovle this issue...
![]()
No comments:
Post a Comment