Saturday, March 24, 2012

Trouble with a page loading when xcopying from localhost to server!

My main webform will not load. I xcopied the entire directory from my computer to the server. One page works, but the main page doesn't load controls or anything, just a white blank page. I put response.writes in the page_load and init functions and they appear when it loads but nothing else! Any ideas? There is a form tag.Sounds like you might not have a "form" tag.
Can you post the html markup?

There is a form tag in the html, but here it is:

Date of Request:Ext.:IS Request #:Originator:Dept Manager:Upload Bulletins



Please select a brandPlease select bulletins to upload for emailing. Note: Uploaded files must be MS Word files. Select Product Bulletin Type

there is a form tag... here is code
It worked locally not on development server..
. Date of Request:Ext.:IS Request #:Originator:Dept Manager:Upload Bulletins



Please select a brandPlease select bulletins to upload for emailing. Note: Uploaded files must be MS Word files. Select Product Bulletin Type

I'm sorry, I meant to post you aspx code for the page. Sorry, I didn't notice that you said you had a <form tag.
You say that another page is working. does it have any server controls on it?
Hey Jim,
Sorry about the double post, I'm new to this forum.. I believe its a sql connection problem. OR not? Here is the code for the connection:

'This will access a SQL database and retreive users name, ext, dept, ID.

Dim cnAsNew SqlConnection("Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=ProductBulletins;Data Source=SERVER") <-generic server

Dim cmdAs SqlCommand
Dim dr As SqlDataReader
Try
cn.Open()
cmd = New SqlCommand("usp_SELECTBYUSERNAME", cn)
cmd.CommandType = CommandType.StoredProcedure
cmd.Parameters.Add("@.username", user)
dr = cmd.ExecuteReader(CommandBehavior.SingleRow)
dr.Read()
lblOriginator.Text = dr.Item("FirstName") + " " + dr.Item("LastName")
lblExt.Text = dr.Item("Extension")
lblDeptManager.Text = dr.Item("Department")
userID = dr.Item("ID")
Catch ex As Exception
Response.Redirect("ErrorSuccess.aspx?Err=1" + Context.Server.GetLastError.Message)
Finally
dr.Close()
cn.Close()
EndTry
EndSub

0 comments:

Post a Comment