Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
jhermiz
3564 Posts |
Posted - 2007-07-10 : 09:04:51
|
Created a site works totally fine on my local machine.So I tried using the copy project in VS.net 2005 but it complains the server does not have FrontPage server extensions installed (Even though they are installed). However this site is not on the root of the C:\Inetpub\wwwroot directory on the server. I had to create a sub folder...So Im wondering if that has anything to do with the complaint aobut not having Front page server ext. installed.In any event I just went ahead and copied the project and all the files manually...but when I go to the site directly on the web server I get strange errors about lines in my code for things such as exception handling. I even get an error about it not being able to find a table...Cannot find table 0. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.IndexOutOfRangeException: Cannot find table 0.Source Error: Line 299: Dim nextDate As DateTimeLine 300: If Not CType(Session("dsHolidays"), DataSet) Is Nothing ThenLine 301: For Each dr As DataRow In CType(Session("dsHolidays"), DataSet).Tables(0).RowsLine 302: nextDate = CType(dr("HolidayDate"), DateTime)Line 303: If nextDate = e.Day.Date Then Even though the table is valid...Not sure what is wrong ?Programmers HowTo's -- [url]http://jhermiz.googlepages.com[/url] |
|
jsmith8858
Dr. Cross Join
7423 Posts |
Posted - 2007-07-10 : 09:40:42
|
Your dataset wasn't filled for some reason -- it doesn't contain any tables. Are you sure your connection strings are OK, and that if you are pointing to a new database, it has the data you need? Add a breakpoint after the dataset is filled and check it out to ensure it has the tables you expect.Also, if you are only using 1 table in a dataset, just store the dataTable instead -- it is waste to put a whole dataset in memory when all you need is a data table.- Jeffhttp://weblogs.sqlteam.com/JeffS |
|
|
jhermiz
3564 Posts |
Posted - 2007-07-10 : 09:51:19
|
quote: Originally posted by jsmith8858 Your dataset wasn't filled for some reason -- it doesn't contain any tables. Are you sure your connection strings are OK, and that if you are pointing to a new database, it has the data you need? Add a breakpoint after the dataset is filled and check it out to ensure it has the tables you expect.Also, if you are only using 1 table in a dataset, just store the dataTable instead -- it is waste to put a whole dataset in memory when all you need is a data table.- Jeffhttp://weblogs.sqlteam.com/JeffS
Well the app uses windows authentication and somehow I think it is not authenticating me...I'm not getting the IE pop up asking for user name and password (domain\user name)...So something tells me the dataset isnt filling cause its not getting me...But this only happens when I try to get to the site that is sitting on the web server. Locally in IE7 this works fine...a peer sitting next to me can get to the site absolutely fine in IE6 and she gets authenticated because her data shows up.So Im puzzled...Programmers HowTo's -- [url]http://jhermiz.googlepages.com[/url] |
|
|
jhermiz
3564 Posts |
Posted - 2007-07-10 : 10:16:29
|
By the way the site works 100% in firefox, it asks for a user name and password which I give it my domain\username and my password and once I hit enter the site opens fine. So I tried something else..went directly to the server and opened the IE browser (IE 6) and typed in a user name and password (not mine, just the local admin) and I get an error that same error about that table (not getting the data in the dataset). But if I do the same thing and type in my credentials (IE 6 opens up a login screen to try to authenticate me) and I put in my user name and password, it works perfectly fine.So what this is telling me is somehow on my machine when I try to hit the server it doesnt realize who I am (doesnt authenticate me).Programmers HowTo's -- [url]http://jhermiz.googlepages.com[/url] |
|
|
jhermiz
3564 Posts |
Posted - 2007-07-10 : 10:21:15
|
I think it has something to do with the way IE7 handles integrated windows authentication differently than IE6...thats the only thing I can think of because two test boxes running IE6 were both able to bring up the site with no problems...Programmers HowTo's -- [url]http://jhermiz.googlepages.com[/url] |
|
|
jsmith8858
Dr. Cross Join
7423 Posts |
Posted - 2007-07-10 : 10:28:31
|
It could also be the security settings within the browsers themselves ... maybe poke around the settings in IE7 to see if anything jumps out at you?- Jeffhttp://weblogs.sqlteam.com/JeffS |
|
|
jhermiz
3564 Posts |
Posted - 2007-07-10 : 10:50:13
|
quote: Originally posted by jsmith8858 It could also be the security settings within the browsers themselves ... maybe poke around the settings in IE7 to see if anything jumps out at you?- Jeffhttp://weblogs.sqlteam.com/JeffS
Ya that is what I have been trying. What I did find is an area in the IE 7 options to change the "Custom Level" options of a web site on the Intra Net zone. I changed it from Use automatic login to Intranet zone to "Prompt for user name and password"...Went to the site and the popup came up to type in my user name and password. In the user name instead of my user name it has "Administrator" and no password specified...so it was trying to authenticate an administrator which is not even in the system (has no data in the system). As soon as I changed it to my user name and password (nt credentials) it worked fine.Now the million dollar question is why does it take in administrator and not my user name in IE7...what is causing that ? Why isnt it taking my current user name and password and storing it ?Very strange...but im getting very close to finding out why...Programmers HowTo's -- [url]http://jhermiz.googlepages.com[/url] |
|
|
jhermiz
3564 Posts |
Posted - 2007-07-10 : 11:53:28
|
Err I know Im close but not sure where to look, I rebooted my machine and I have it set to prompt for user name and password just to see who it thinks I am. It always enters "administrator" for me even though I have logged in with my user name and password. Shouldnt it be using the nt credentials? What is making IE7 use the administrator account ???Programmers HowTo's -- [url]http://jhermiz.googlepages.com[/url] |
|
|
|
|
|
|
|