Wrox Programmer Forums
|
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Dreamweaver (all versions) section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 4th, 2006, 09:55 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default rs.eof returns false

Hello
I have a recordset with a filter that gets its value from perivious page.some times the value that users select in the first page is not in the database so it returns the eof or bof error .
I attached a code for viewing a friendly message instead of error page but it always write flase.
the code is:
 <% if rs.EOF or rs.BOF then
Response.Write("Your requested Site does not have any information yet !"<br>"Please Contact for this site Later")
else
%>
<show the page>
<%end if%>
but it shows false when it is eof or bof.
Is there any one can help me ?
thank you

 
Old February 4th, 2006, 10:37 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

What do you mean with "it shows false when it is eof or bof"? If the recordset does not contain records, EOF is True, otherwise it's False. E.g.:

If myRecordset.EOF Then
  ' No records
Else
  ' Records
End If

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
 
Old February 4th, 2006, 11:01 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default


I mean it shows a page that has my banner and other grafic things in it and in the place that should wrote the string that i wrote it with response write it writes "false" when it is bof or eof and when it is not it shows the page correctly


 
Old February 4th, 2006, 11:08 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default

excuse me.I made a very bad mistake and now the problem has fixed.
thank you Mr Imar






Similar Threads
Thread Thread Starter Forum Replies Last Post
RecordCount Query returns EOF and BOF jigs_bhavsar Pro VB Databases 3 November 11th, 2004 09:32 AM
EOF always false with wildcard pacejohn Access VBA 1 August 20th, 2004 12:44 AM
SQL result returns nothing, but empty == false? barddzen Pro JSP 1 August 9th, 2004 12:52 AM
RS Manager and RS Server on 2 different computers Choose File BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 1 July 22nd, 2004 10:56 AM
rs.find - returns error3001 doreenjj VB Databases Basics 2 November 20th, 2003 07:43 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.