Ask a Question related to Macromedia Dreamweaver, Design and Development.
-
artane webforumsuser@macromedia.com #1
Re: I'm using ASP, do I need an application.cfm file?
Hi Silicon,
I've been looking around for the "global.asa" file but, I can't find it. Do I have to create it myself? If so, where?
I've got a simple login page. When the user logs in, they are directed to a "homepage" that I want to display all of their personal information (pulled from the databse). On the "homepage", I've got some dynamic text fields and I've defined a recordset but I get this error message:
ADODB.Field error '800a0bcd'
Either BOF or EOF is True, or the current record has been deleted. Requested operation requires a current record.
/asp-letsplay.tv/pages/TMP253nhqkhm.asp, line 33
Do you know what this means? I suspect it has something to do with the "global.asa" file. Maybe I'm not filtering my recordset properly, what should I do?
Thanks very much for your help!
artane
artane webforumsuser@macromedia.com Guest
-
Rasterize a pdf-file for use in a c++ application
Hi, I wrote an c++ application which compares pdf-files to cameraimages. This application has to load the pdfs and convert them to bitmaps. Now... -
URL redirect in application file
hi, I am trying to direct users from a URL they can put directly in the browser. The URL they put in might look like this: ... -
How do I bypass an Application.cfm file?
I have an application that uses the CF Security Framework (Application.cfm, cflogin, cfloginuser), Apache, and MySQL to handle the log in process.... -
TO run an Application from Batch file
Hi, I want to run the batch file from the asp.net web(intranet)application. The batch files works fine if it has some copy or del command,... -
Can not resize and then use file in another application
When i resize a pic and save, I cannot use the file in Avery Label pro or Kodak viewer, It will work in Word. What am i doin wrong. Please respond t... -
Silicon9 webforumsuser@macromedia.com #2
Re: I'm using ASP, do I need an application.cfm file?
artane
I can assure you that your current woes have nothing to do with the global.asa, the error you are getting simply means that your recordset is empty, nada, nuttin' thar, zip-a-roony.
Based on what you are doing, you shouldn't need to use recordset filtering at all, there should only be one record (for the user that logged in). Never select ALL of the records and filter if you only need one of the records. (bad practice)
So, let's get this straight;
1) your user authenticates
2) you pass the user's unique record id (userid) to the homepage
3) as the homepage is generated, you grab the users record from access -
rsMyUser = (SELECT * from tblUsers WHERE recordID = (userid))
4) Then you display his/her information on the page using
<% = rsMyUser.Fields("FirstName").value %> etc..........
The two areas for this process to most likely breakdown are;
1) The users recordID is not being passed along properly in your SELECT statement.
2) The recordID that is getting passed returns no rows to your page.
Let's do a little debugging..........
First, comment out all of the dynamic text and fields on your page. (this will temporarily get rid of that error, because you are not trying to display the empty recordset)
Now, somewhere near the top of your page (between the <body> tags) take a look at the value you passed to this page with the Request Object.
<% = Request("?") %> you will need to use whatever you named the user's recordID.
Test the page
If the correct value is displayed, then let's put a <%= (YourRecordsetName_total) %> line on your page to make sure at least the one record is getting returned.
Test again
these two little tests will help you to determine if the correct value is being passed, and if a recordset is being retured at all.
Once you check these things out, and fix your current problem, we can get into the uses of the global.asa
Si9
<SCRIPT LANGUAGE="VBScript" RUNAT="Server">
Sub Application_OnStart
'... your code here
End Sub
Sub Application_OnEnd
'... your code here
End Sub
Sub Session_OnStart
'... your code here
End Sub
Sub Session_OnEnd
'... your code here
End Sub
</SCRIPT>
Silicon9 webforumsuser@macromedia.com Guest
-
artane webforumsuser@macromedia.com #3
Re: I'm using ASP, do I need an application.cfm file?
Hi Silicon,
Thanks alot for breaking that down. It doesn't seem so confusing to me anymore.
I think I may know what the problem is. I don't seem to have the "request object" you refered to. You mentioned this:
(between the <body> tags) take a look at the value you passed to this page with the Request Object. <% = Request("?") %> you will need to use whatever you named the user's recordID.
I don't have this. I suspect I haven't passed anything to this page. Here is my code:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<!--#include file="../Connections/new_database.asp" -->
<%
Dim Recordset1
Dim Recordset1_numRows
Set Recordset1 = Server.CreateObject("ADODB.Recordset")
Recordset1.ActiveConnection = MM_new_database_STRING
Recordset1.Source = "SELECT * FROM members"
Recordset1.CursorType = 0
Recordset1.CursorLocation = 2
Recordset1.LockType = 1
Recordset1.Open()
Recordset1_numRows = 0
%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<p>Home Page </p>
<p>nickname: </p>
</body>
</html>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>
What do you think Silicon? Thanks alot for your help!
artane
artane webforumsuser@macromedia.com Guest
-
artane webforumsuser@macromedia.com #4
Re: I'm using ASP, do I need an application.cfm file?
Thanks alot Silicon9!
This should keep me busy for a while, I'm going to get right on it!
artane :)
artane webforumsuser@macromedia.com Guest



Reply With Quote

