Thursday, March 29, 2012

missing pictures and stylesheet-information

you you using relative or absolute pathing for the images? is "allow parent
paths" turned on in the IIS config? Most likely it's a config issue of that
type. Go through the IIS settings tab by tab.

--
Curt Christianson
Owner/Lead Developer, DF-Software
Site: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com

"Patrick Rogalski" <anonymous@dotnet.itags.org.discussions.microsoft.com> wrote in message
news:68C48ADC-276A-438E-903E-E7AEE77AD6ED@dotnet.itags.org.microsoft.com...
> Hi,
> I have the following problem in one customer-environment: the pages in the
browser are not displayed properly. The pictures and styles from the
stylesheet are missing (I can only see the placeholder and the colors are
missing). If I have a look to the sources of the page in the browser (IE6),
the content of all src-tags are ok. If I type the adress of the picture
direct into the adressline, the browser shows the picture. The pictures and
stylesheets are available, the page has all required src-tags but they are
not displayed. I have a few installations of this application, but only this
one works not properly.
> Any ideas what it can be ? Would be very great... Thanks Patrick :o)Hi

yes I use relative pathing. I've deactivated this option on my own system, but it still works properly. I'll try it on the customers system

Thanks Patrick

Missing QueryStirng?

I'm integrating my application with a Flash front-end and when the Flash
requests my login page with ?login=x&password=y queryString appeded to the
URL, this information get's lost.
If I put the entire URL in my browser, everything goes fine, but, when I
call it from Flash the query string is missing and I get to my login page.
Is there any issue in starting calling a ASP.Net app from another site with
a queryString appended to the loginForm's URL? (really getting crazy!!!)
Thanks for any help,
Regards,
Victor ReboucasWe can't really give you an answer without you posting the relevant code.
However, you do not want to be passing the password in the query string -
not secure at all.
"VR" <vcreb@.hotmail.com> wrote in message
news:%23IHF0vGaFHA.3784@.TK2MSFTNGP12.phx.gbl...
> I'm integrating my application with a Flash front-end and when the Flash
> requests my login page with ?login=x&password=y queryString appeded to the
> URL, this information get's lost.
> If I put the entire URL in my browser, everything goes fine, but, when I
> call it from Flash the query string is missing and I get to my login page.
> Is there any issue in starting calling a ASP.Net app from another site
> with a queryString appended to the loginForm's URL? (really getting
> crazy!!!)
>
> Thanks for any help,
> Regards,
> Victor Reboucas
>
Really sorry about this post...
The guy was sending my the values using POST, but told me he was using
GET...
sorry,
Victor Reboucas
"Marina" <someone@.nospam.com> wrote in message
news:epv$5xGaFHA.616@.TK2MSFTNGP12.phx.gbl...
> We can't really give you an answer without you posting the relevant code.
> However, you do not want to be passing the password in the query string -
> not secure at all.
> "VR" <vcreb@.hotmail.com> wrote in message
> news:%23IHF0vGaFHA.3784@.TK2MSFTNGP12.phx.gbl...
>

Missing QueryStirng?

I'm integrating my application with a Flash front-end and when the Flash
requests my login page with ?login=x&password=y queryString appeded to the
URL, this information get's lost.

If I put the entire URL in my browser, everything goes fine, but, when I
call it from Flash the query string is missing and I get to my login page.

Is there any issue in starting calling a ASP.Net app from another site with
a queryString appended to the loginForm's URL? (really getting crazy!!!)

Thanks for any help,
Regards,
Victor ReboucasWe can't really give you an answer without you posting the relevant code.

However, you do not want to be passing the password in the query string -
not secure at all.

"VR" <vcreb@.hotmail.com> wrote in message
news:%23IHF0vGaFHA.3784@.TK2MSFTNGP12.phx.gbl...
> I'm integrating my application with a Flash front-end and when the Flash
> requests my login page with ?login=x&password=y queryString appeded to the
> URL, this information get's lost.
> If I put the entire URL in my browser, everything goes fine, but, when I
> call it from Flash the query string is missing and I get to my login page.
> Is there any issue in starting calling a ASP.Net app from another site
> with a queryString appended to the loginForm's URL? (really getting
> crazy!!!)
>
> Thanks for any help,
> Regards,
> Victor Reboucas
Really sorry about this post...

The guy was sending my the values using POST, but told me he was using
GET...

sorry,
Victor Reboucas

"Marina" <someone@.nospam.com> wrote in message
news:epv$5xGaFHA.616@.TK2MSFTNGP12.phx.gbl...
> We can't really give you an answer without you posting the relevant code.
> However, you do not want to be passing the password in the query string -
> not secure at all.
> "VR" <vcreb@.hotmail.com> wrote in message
> news:%23IHF0vGaFHA.3784@.TK2MSFTNGP12.phx.gbl...
>> I'm integrating my application with a Flash front-end and when the Flash
>> requests my login page with ?login=x&password=y queryString appeded to
>> the URL, this information get's lost.
>>
>> If I put the entire URL in my browser, everything goes fine, but, when I
>> call it from Flash the query string is missing and I get to my login
>> page.
>>
>> Is there any issue in starting calling a ASP.Net app from another site
>> with a queryString appended to the loginForm's URL? (really getting
>> crazy!!!)
>>
>>
>> Thanks for any help,
>> Regards,
>> Victor Reboucas
>>

Missing Referring URL in log files

We have a strange situation where some of the referring URL's are
missing from our log files. This is on .NET application on IIS 6.0.
Here is what is happening:

Page a.aspx has a form that POST's to a.aspx. If there are errors with
the form information, then a.aspx is displayed with an error message to
the user.

If all the information is correct then it is redirected
(response.redirect) - GET to page b.aspx. In this GET to b.aspx (and
only in the GET by redirect), the referring URL is not being saved in
IIS log files.

Does anyone have any ideas on how we can fix this?

Thanksit has nothing to do with .net the browser is responsible for sending
the referring url. you browser is not sending one a redirect.

note: some proxy server will always strip the referring url for security
reasons.

-- bruce (sqlwork.com)

paladin wrote:

Quote:

Originally Posted by

We have a strange situation where some of the referring URL's are
missing from our log files. This is on .NET application on IIS 6.0.
Here is what is happening:
>
Page a.aspx has a form that POST's to a.aspx. If there are errors with
the form information, then a.aspx is displayed with an error message to
the user.
>
If all the information is correct then it is redirected
(response.redirect) - GET to page b.aspx. In this GET to b.aspx (and
only in the GET by redirect), the referring URL is not being saved in
IIS log files.
>
Does anyone have any ideas on how we can fix this?
>
Thanks
>


I managed to narrow it down to the Mozilla version in the browser. v4.0
does not send the referrer while v5.0 does. The strange thing is that I
have IE7 with Mozilla 4.0 (does not send the referrer) while my boss
has IE6 with Mozilla 5.0 (his send the referrer).

Do you know if there is a way to programatically add the referrer in
the case of v4.0 so that it shows up in the IIS logs.

Another thing we are seeing is that the .NET redirects the user from
mydomain.com/folder/file.aspx to
mydomain.com/(S(sessionID))folder/file.aspx. This (S(sessionID)) shows
up in the referring URL in the logs but not in the requested file path
column. Any ideas?

thanks
Alon

bruce barker wrote:

Quote:

Originally Posted by

it has nothing to do with .net the browser is responsible for sending
the referring url. you browser is not sending one a redirect.
>
note: some proxy server will always strip the referring url for security
reasons.
>
-- bruce (sqlwork.com)
>
paladin wrote:

Quote:

Originally Posted by

We have a strange situation where some of the referring URL's are
missing from our log files. This is on .NET application on IIS 6.0.
Here is what is happening:

Page a.aspx has a form that POST's to a.aspx. If there are errors with
the form information, then a.aspx is displayed with an error message to
the user.

If all the information is correct then it is redirected
(response.redirect) - GET to page b.aspx. In this GET to b.aspx (and
only in the GET by redirect), the referring URL is not being saved in
IIS log files.

Does anyone have any ideas on how we can fix this?

Thanks

Missing Referring URL in log files

We have a strange situation where some of the referring URL's are
missing from our log files. This is on .NET application on IIS 6.0.
Here is what is happening:
Page a.aspx has a form that POST's to a.aspx. If there are errors with
the form information, then a.aspx is displayed with an error message to
the user.
If all the information is correct then it is redirected
(response.redirect) - GET to page b.aspx. In this GET to b.aspx (and
only in the GET by redirect), the referring URL is not being saved in
IIS log files.
Does anyone have any ideas on how we can fix this?
Thanksit has nothing to do with .net the browser is responsible for sending
the referring url. you browser is not sending one a redirect.
note: some proxy server will always strip the referring url for security
reasons.
-- bruce (sqlwork.com)
paladin wrote:
> We have a strange situation where some of the referring URL's are
> missing from our log files. This is on .NET application on IIS 6.0.
> Here is what is happening:
> Page a.aspx has a form that POST's to a.aspx. If there are errors with
> the form information, then a.aspx is displayed with an error message to
> the user.
> If all the information is correct then it is redirected
> (response.redirect) - GET to page b.aspx. In this GET to b.aspx (and
> only in the GET by redirect), the referring URL is not being saved in
> IIS log files.
> Does anyone have any ideas on how we can fix this?
> Thanks
>
I managed to narrow it down to the Mozilla version in the browser. v4.0
does not send the referrer while v5.0 does. The strange thing is that I
have IE7 with Mozilla 4.0 (does not send the referrer) while my boss
has IE6 with Mozilla 5.0 (his send the referrer).
Do you know if there is a way to programatically add the referrer in
the case of v4.0 so that it shows up in the IIS logs.
Another thing we are seeing is that the .NET redirects the user from
mydomain.com/folder/file.aspx to
mydomain.com/(S(sessionID))folder/file.aspx. This (S(sessionID)) shows
up in the referring URL in the logs but not in the requested file path
column. Any ideas?
thanks
Alon
bruce barker wrote:
> it has nothing to do with .net the browser is responsible for sending
> the referring url. you browser is not sending one a redirect.
> note: some proxy server will always strip the referring url for security
> reasons.
> -- bruce (sqlwork.com)
> paladin wrote:

Missing required parameter error

I've distilled this down into the simplest possible code fragment and
this still doesn't make any sense. I'm trying to run a select query on
an access database, and the query has NO parameters. And yet, I'm
still getting a "No value given for one or more required parameters"
error. What gives?

Here's my code. I put it in a Form_Load subroutine of a blank .aspx
page so that nothing else external would affect it. (And yes, the
Access database is meant to have a user name and password.)

Protected Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs)
Dim myConnection As System.Data.OleDb.OleDbConnection
Dim connStr As String
connStr = String.Format("Provider=Microsoft.Jet.OLEDB.4.0; Data
Source=" & Server.MapPath(MyGlobals.ACCESS_DB) & "; " & _
"Persist Security Info=True; Jet
OLEDB:Engine Type=5; Jet OLEDB:System Database=" & _
MyGlobals.ACCESS_SYSTEM_MDW & "; User
ID=" & _
"XXXXX" & "; Password=" & _
"XXXXX")
myConnection = New System.Data.OleDb.OleDbConnection(connStr)
Dim mySelectQuery As String
Dim myCommand As New System.Data.OleDb.OleDbCommand()

mySelectQuery = "SELECT EmployeeID, LastName, FirstName,
EmpFileNumber " & _
"FROM employees"
myCommand = New System.Data.OleDb.OleDbCommand(mySelectQuery,
myConnection)

myConnection.Open()

Dim myReader As System.Data.OleDb.OleDbDataReader
myReader =
myCommand.ExecuteReader(System.Data.CommandBehavio r.CloseConnection)
<-- error happens here

myConnection = Nothing
End Sub

Any ideas, anyone?

Damonadd
myCommand.CommandType = CommandType.Text
before the execute.

Regards,

Trevor Benedict R
MCSD

"Damon" <kowa@.redshift.com> wrote in message
news:1140469727.000825.71270@.g43g2000cwa.googlegro ups.com...
> I've distilled this down into the simplest possible code fragment and
> this still doesn't make any sense. I'm trying to run a select query on
> an access database, and the query has NO parameters. And yet, I'm
> still getting a "No value given for one or more required parameters"
> error. What gives?
> Here's my code. I put it in a Form_Load subroutine of a blank .aspx
> page so that nothing else external would affect it. (And yes, the
> Access database is meant to have a user name and password.)
> Protected Sub Form1_Load(ByVal sender As System.Object, ByVal e As
> System.EventArgs)
> Dim myConnection As System.Data.OleDb.OleDbConnection
> Dim connStr As String
> connStr = String.Format("Provider=Microsoft.Jet.OLEDB.4.0; Data
> Source=" & Server.MapPath(MyGlobals.ACCESS_DB) & "; " & _
> "Persist Security Info=True; Jet
> OLEDB:Engine Type=5; Jet OLEDB:System Database=" & _
> MyGlobals.ACCESS_SYSTEM_MDW & "; User
> ID=" & _
> "XXXXX" & "; Password=" & _
> "XXXXX")
> myConnection = New System.Data.OleDb.OleDbConnection(connStr)
> Dim mySelectQuery As String
> Dim myCommand As New System.Data.OleDb.OleDbCommand()
> mySelectQuery = "SELECT EmployeeID, LastName, FirstName,
> EmpFileNumber " & _
> "FROM employees"
> myCommand = New System.Data.OleDb.OleDbCommand(mySelectQuery,
> myConnection)
> myConnection.Open()
> Dim myReader As System.Data.OleDb.OleDbDataReader
> myReader =
> myCommand.ExecuteReader(System.Data.CommandBehavio r.CloseConnection)
> <-- error happens here
> myConnection = Nothing
> End Sub
> Any ideas, anyone?
> Damon

Missing Rows in a DataBind()

Hey all,
Have a strange one here, and being still fairly new to .NET isn't helping me
understand it.
I am having a problem where a DataReader doesn't return all the rows when I
try to use a method from a separate class file that returns a DataReader,
where when I code the DataReader in the .aspx file it does. Below are the
details and code of what I am runnign into. I appreciate any help/insight
you can provide.
I am working on a fairly simple app that allow a user to add/update/delete
meeting minutes and agendas. I have a database (SQL Server 2000) storing
some simple info, and a directory the Mins/Agnd PDF file is uploaded to. I
created a little web user control that uses a DataGrid and DropDown listbox.
I bind each one separately, and use stored procedures to query the DB.
Originally I did the following function, called in the page's OnLoad method
only if Page.IsPostback was false:
Private Sub BindYearDropDown()
Dim con As New
SqlConnection(ConfigurationSettings.AppSettings("SQLServer_BOS"))
Dim cmd As SqlCommand = New SqlCommand("spAgendas_GetAllAgendaYears", con)
lstAgendas.DataSource = cmd.ExecuteReader(CommandBehavior.CloseConnection)
lstAgendas.DataTextField = "Year"
lstAgendas.DataValueField = "Year"
lstAgendas.DataBind()
End Sub
(My S-Proc is a basic "SELECT DISTINCT vYear FROM MyTable ORDER BY vYear
DESC")
All this does is populate a DropDown list with the distinct years in the DB
(2000 through 2004 in my case). I decided to use a DataReader beacuase I am
not doing two-way communication, and also the DR runs much faster due to
lesser overhead requirements. Well, as I was building this app, I started
to have more and more methods needing to talk to the DB. Well, I wanted to
create a single function that I could just call and it would return a set of
records that I could rummage through or bind to data sources. This way I
could just reuse the same method over and over, and if anything in my DB
connection changed, I didn't have to worry about finding all the location
throughout the app and missing some change.
So, I created the following function in a "business objects" class file:
Public Function GetADataReader(ByVal sSQL As String) As SqlDataReader
Dim con As New
SqlConnection(ConfigurationSettings.AppSettings("SQLServer_BOS"))
Dim cmd As SqlCommand = New SqlCommand(sSQL, con)
Dim dr As SqlDataReader
Try
con.Open()
dr = cmd.ExecuteReader(CommandBehavior.CloseConnection)
dr.Read()
Return dr
Catch ex As Exception
Throw
End Try
End Function
And then I altered my binding method back in my control to the following
(BoardBO is my "business objects" class file):
Private Sub BindYearDropDown()
lstAgendas.DataSource =
BoardBO.GetADataReader("spAgendas_GetAllAgendaYears")
lstAgendas.DataTextField = "Year"
lstAgendas.DataValueField = "Year"
lstAgendas.DataBind()
End Sub
And now we get to my question/problem. When I did it the first way, I got
all five years (2004 through 2000). Yet when I do it the second way, I only
get 4 years (2003 through 2000). I debugged the code by adding a breakpoint
on the GetADataReader method and stepping through it one line at a time.
After the dr.Read() call, in the command window I typed "?dr(0)" and it gave
me "2004", yet once the DataBind() method of the BindYearDropDown method is
called, "2004" is nowhere to be seen. Huh? I don't get this.
Wondering if it was something about a "remote" DataReader method, I also
created a "remote" DataSet method to do the exact same thing, but using a
DataSet object vice a SQLDataReader. That function is :
Public Function GetADataSet(ByVal sSQL As String) As DataSet
Dim con As String =
ConfigurationSettings.AppSettings("SQLServer_BOS")
Dim da As New SqlDataAdapter(sSQL, con)
Dim ds As New DataSet
Try
da.Fill(ds)
Return ds
Catch ex As Exception
Throw
End Try
End Function
And then I changed my dropdown list data bind method to:
Private Sub BindYearDropDown()
lstAgendas.DataSource =
BoardBO.GetADataSet("spAgendas_GetAllAgendaYears").Tables(0)
lstAgendas.DataTextField = "Year"
lstAgendas.DataValueField = "Year"
lstAgendas.DataBind()
End Sub
Low and behold, I got all five years once again (2004 - 2000)!
What is it about doing this with a DataSet instead of a DataReader that
gives me all my data? Why is the DataReader method loosing the first row in
the returned records? I don't understand this.
If you can help me to understand what is happening, I sure would appreciate
it. Thanks!!
-- AndrewYou call .Read before you return the erader - which advances the reader to
the first row. I assume your problem is always missing the first row from
the result set? Well, this is why.
"Andrew" <AndrewR2k1@.hotmail.com> wrote in message
news:eKv185lHEHA.828@.TK2MSFTNGP12.phx.gbl...
> Hey all,
> Have a strange one here, and being still fairly new to .NET isn't helping
me
> understand it.
> I am having a problem where a DataReader doesn't return all the rows when
I
> try to use a method from a separate class file that returns a DataReader,
> where when I code the DataReader in the .aspx file it does. Below are the
> details and code of what I am runnign into. I appreciate any help/insight
> you can provide.
> I am working on a fairly simple app that allow a user to add/update/delete
> meeting minutes and agendas. I have a database (SQL Server 2000) storing
> some simple info, and a directory the Mins/Agnd PDF file is uploaded to.
I
> created a little web user control that uses a DataGrid and DropDown
listbox.
> I bind each one separately, and use stored procedures to query the DB.
> Originally I did the following function, called in the page's OnLoad
method
> only if Page.IsPostback was false:
> Private Sub BindYearDropDown()
> Dim con As New
> SqlConnection(ConfigurationSettings.AppSettings("SQLServer_BOS"))
> Dim cmd As SqlCommand = New SqlCommand("spAgendas_GetAllAgendaYears",
con)
> lstAgendas.DataSource =
cmd.ExecuteReader(CommandBehavior.CloseConnection)
> lstAgendas.DataTextField = "Year"
> lstAgendas.DataValueField = "Year"
> lstAgendas.DataBind()
> End Sub
> (My S-Proc is a basic "SELECT DISTINCT vYear FROM MyTable ORDER BY vYear
> DESC")
> All this does is populate a DropDown list with the distinct years in the
DB
> (2000 through 2004 in my case). I decided to use a DataReader beacuase I
am
> not doing two-way communication, and also the DR runs much faster due to
> lesser overhead requirements. Well, as I was building this app, I started
> to have more and more methods needing to talk to the DB. Well, I wanted
to
> create a single function that I could just call and it would return a set
of
> records that I could rummage through or bind to data sources. This way I
> could just reuse the same method over and over, and if anything in my DB
> connection changed, I didn't have to worry about finding all the location
> throughout the app and missing some change.
> So, I created the following function in a "business objects" class file:
> Public Function GetADataReader(ByVal sSQL As String) As SqlDataReader
> Dim con As New
> SqlConnection(ConfigurationSettings.AppSettings("SQLServer_BOS"))
> Dim cmd As SqlCommand = New SqlCommand(sSQL, con)
> Dim dr As SqlDataReader
> Try
> con.Open()
> dr = cmd.ExecuteReader(CommandBehavior.CloseConnection)
> dr.Read()
> Return dr
> Catch ex As Exception
> Throw
> End Try
> End Function
> And then I altered my binding method back in my control to the following
> (BoardBO is my "business objects" class file):
> Private Sub BindYearDropDown()
> lstAgendas.DataSource =
> BoardBO.GetADataReader("spAgendas_GetAllAgendaYears")
> lstAgendas.DataTextField = "Year"
> lstAgendas.DataValueField = "Year"
> lstAgendas.DataBind()
> End Sub
> And now we get to my question/problem. When I did it the first way, I got
> all five years (2004 through 2000). Yet when I do it the second way, I
only
> get 4 years (2003 through 2000). I debugged the code by adding a
breakpoint
> on the GetADataReader method and stepping through it one line at a time.
> After the dr.Read() call, in the command window I typed "?dr(0)" and it
gave
> me "2004", yet once the DataBind() method of the BindYearDropDown method
is
> called, "2004" is nowhere to be seen. Huh? I don't get this.
> Wondering if it was something about a "remote" DataReader method, I also
> created a "remote" DataSet method to do the exact same thing, but using a
> DataSet object vice a SQLDataReader. That function is :
> Public Function GetADataSet(ByVal sSQL As String) As DataSet
> Dim con As String =
> ConfigurationSettings.AppSettings("SQLServer_BOS")
> Dim da As New SqlDataAdapter(sSQL, con)
> Dim ds As New DataSet
> Try
> da.Fill(ds)
> Return ds
> Catch ex As Exception
> Throw
> End Try
> End Function
> And then I changed my dropdown list data bind method to:
> Private Sub BindYearDropDown()
> lstAgendas.DataSource =
> BoardBO.GetADataSet("spAgendas_GetAllAgendaYears").Tables(0)
> lstAgendas.DataTextField = "Year"
> lstAgendas.DataValueField = "Year"
> lstAgendas.DataBind()
> End Sub
> Low and behold, I got all five years once again (2004 - 2000)!
> What is it about doing this with a DataSet instead of a DataReader that
> gives me all my data? Why is the DataReader method loosing the first row
in
> the returned records? I don't understand this.
> If you can help me to understand what is happening, I sure would
appreciate
> it. Thanks!!
> -- Andrew
>
Damn, I took all that time and effort to write up the message and you go an
solve it in three lines. I guess .Net is more productive. :) Thanks for
the help, it was right on the money!
-- Andrew
"Marina" <someone@.nospam.com> wrote in message
news:uxq6d$lHEHA.1220@.tk2msftngp13.phx.gbl...
> You call .Read before you return the erader - which advances the reader to
> the first row. I assume your problem is always missing the first row from
> the result set? Well, this is why.
> "Andrew" <AndrewR2k1@.hotmail.com> wrote in message
> news:eKv185lHEHA.828@.TK2MSFTNGP12.phx.gbl...
helping
> me
when
> I
DataReader,
the
help/insight
add/update/delete
storing
> I
> listbox.
> method
> con)
> cmd.ExecuteReader(CommandBehavior.CloseConnection)
> DB
I
> am
started
> to
set
> of
I
location
SqlDataReader
got
> only
> breakpoint
> gave
> is
a
row
> in
> appreciate
>