Putting my FIRST ASP.NET baby on the net :-)
-
Hi all, Im a university computer science student and just finished my coolest project in school so far....an ASP.NET site that connects and gets data from an Access database. Everything works fine when I run it on the local IIS but when I try to move it to the internet...all hell breaks loose! :-( First the page didn´t run (because IIS wasn´t connected to my home directory on the web) so I talked to the system admin in school and got that fixed. Then I kept getting those strange errors in my code when Im opening the OLEDB connection. First I thought it was the Access to I CREATED IT ALL AGAIN in MSSQL but still no luck. Dunno if it helps, but when I catch the error and display it, it says: --------------------------------------------------- Message: Request failed. Source: Test Source: at Test.BaseDocument.LoadData(String strSQL) at Test.FlytjandiDocument.LoadFlytjandi(String strColumn, String strSearch) in c:\inetpub\wwwroot\klassikfm\flytjandidocument.cs:line 51 at Test.UserControls.DisplayStudents.FillList(String strSortColumn) in c:\inetpub\wwwroot\klassikfm\usercontrols\flytjendursyna.ascx.cs:line 29 at Test.UserControls.DisplayStudents.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\klassikfm\usercontrols\flytjendursyna.ascx.cs:line 56 at System.Web.UI.Control.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain() --------------------------------------------------- I really really want to get this to the web!!! Thank all those who answer :rose: :-)
-
Hi all, Im a university computer science student and just finished my coolest project in school so far....an ASP.NET site that connects and gets data from an Access database. Everything works fine when I run it on the local IIS but when I try to move it to the internet...all hell breaks loose! :-( First the page didn´t run (because IIS wasn´t connected to my home directory on the web) so I talked to the system admin in school and got that fixed. Then I kept getting those strange errors in my code when Im opening the OLEDB connection. First I thought it was the Access to I CREATED IT ALL AGAIN in MSSQL but still no luck. Dunno if it helps, but when I catch the error and display it, it says: --------------------------------------------------- Message: Request failed. Source: Test Source: at Test.BaseDocument.LoadData(String strSQL) at Test.FlytjandiDocument.LoadFlytjandi(String strColumn, String strSearch) in c:\inetpub\wwwroot\klassikfm\flytjandidocument.cs:line 51 at Test.UserControls.DisplayStudents.FillList(String strSortColumn) in c:\inetpub\wwwroot\klassikfm\usercontrols\flytjendursyna.ascx.cs:line 29 at Test.UserControls.DisplayStudents.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\klassikfm\usercontrols\flytjendursyna.ascx.cs:line 56 at System.Web.UI.Control.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain() --------------------------------------------------- I really really want to get this to the web!!! Thank all those who answer :rose: :-)
Hi there. Does the caught exception have an
InnerException
? If so, it may have more specific information about the error. Also, since this is an OleDb connection, you can specifically catchOleDbException
errors and iterate through itsErrors
property for OleDb specific error information. -
Hi there. Does the caught exception have an
InnerException
? If so, it may have more specific information about the error. Also, since this is an OleDb connection, you can specifically catchOleDbException
errors and iterate through itsErrors
property for OleDb specific error information.What about Web.config ? There are some strange parameters like "authentication mode="Windows" " and: stateConnectionString="tcpip=127.0.0.1:42424" sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes" Don´t I have to change them on order to make it work on the internet? Thanks :rose:
-
What about Web.config ? There are some strange parameters like "authentication mode="Windows" " and: stateConnectionString="tcpip=127.0.0.1:42424" sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes" Don´t I have to change them on order to make it work on the internet? Thanks :rose:
Hi there. The web.config attributes
stateConnectionString
andsqlConnectionString
on thesessionState
element come into play if yourmode
is set toStateServer
orSQLServer
. How do you want to store session state? Do you want to store it on an external server? How you set those values in yourweb.config
file is completely up to what you decide the needs of your application are. If this is a light-traffic web-site, you'll probably be fine with a sessionState mode ofInProc
. I also disagree with your assertion that themode
attribute of theauthentication
web.config element is a strange parameter. I believe it is incredibly useful. Proper use of this element allows you to specify one of several authentication methods for your application. Sounds to me like you may want to do some studying on ASP.NET configuration[^] in MSDN. Your original message suggested a specific exception at a specific point in your code. Look for anInnerException
to that exception to see if there are additional details that will help you troubleshoot it. Again, if it is an OleDb connection, you are well served to iterate the exception'sErrors
property for additional information useful to troubleshooting. Review the .NET documentation - there are plenty of examples of exception handling you'll find useful. -
Hi there. The web.config attributes
stateConnectionString
andsqlConnectionString
on thesessionState
element come into play if yourmode
is set toStateServer
orSQLServer
. How do you want to store session state? Do you want to store it on an external server? How you set those values in yourweb.config
file is completely up to what you decide the needs of your application are. If this is a light-traffic web-site, you'll probably be fine with a sessionState mode ofInProc
. I also disagree with your assertion that themode
attribute of theauthentication
web.config element is a strange parameter. I believe it is incredibly useful. Proper use of this element allows you to specify one of several authentication methods for your application. Sounds to me like you may want to do some studying on ASP.NET configuration[^] in MSDN. Your original message suggested a specific exception at a specific point in your code. Look for anInnerException
to that exception to see if there are additional details that will help you troubleshoot it. Again, if it is an OleDb connection, you are well served to iterate the exception'sErrors
property for additional information useful to troubleshooting. Review the .NET documentation - there are plenty of examples of exception handling you'll find useful.Yes, you´re right. Im new to ASP.NET programming and I need to read more about it (such as this web.config which I have no idea what´s about) :doh: About the exception, Im simply just catching all exceptions (also OleDb I think) try { ... }catch(Exception ex) { Debug.Fail( ex.Message, ex.Source ); } About this InnterException, I first tried to make a new simple asp.net project which opens an OleDb connections and gets data from one table in an MSSQL database and finally outputs it in a datagrid. It works fine on my local IIS but when i move it online I get this error : System.Security.SecurityException’ I already found something about it on microsoft´s website: http://support.microsoft.com/default.aspx?scid=kb;en-us;320268[^] Do you think the solution would be to put 'FullTrust' rights on my IIS online profile? Many thanks Mike :)