-
WSsteve_skelton13
AskWoody LoungerI’m trying to get to this approach, actually but it’s going in baby steps. I’m having trouble just being able to walk thru the fields in the 1row recordset – I keep EOF/BOF True errors all the time, even if I test for EOF and explicitly call RecordSet.MoveFirst. I can grab the data using code like this:
If Not Result.EOF thenResponse.Write “
” & _
“”
i=0
for each fldF in Result.Fields
Item = fldF.NameItemLength = len(Item)
ItemLengthTrim = ItemLength – 11
ItemName = Left(Item, ItemLengthTrim)j = i mod 3
if j = 0 then
response.write “”
else
response.write “”
end if
i = i + 1next
response.write “” & _
“Referring Agencies
” & ItemName & ” ” & fldF.Value & “ ” & ItemName & ” ” & fldF.Value & “ ”
response.write “
”
end if
But when I try to load the array using very similar code I only get the first field and then BOF – EOF error. Here’s the array loading code:
Query = “SELECT * from SumReferringAgencies;”
Set Result = DataConnection.Execute(Query)If Not Result.EOF then
Result.MoveFirst
end ifDim Referring(35)
Dim ReferringName(35)Count = 1
For Each fldF in Result.Fields
Referring(Count) = fldF.Value
Response.Write Referring(Count) & ““”
ReferringName(Count) = fldF.Name
Response.Write ReferringName(Count) & ““”
Result.MoveNext
Count = Count + 1
next
I don’t know what exactly is causing the problem but part of it has to do with using the correct method for calling the Field NAME or the Field VALUE. If I try Do While not Result.EOF the fldF.Name/Value variables don’t function at all. Here’s similar, working array-loading code for a SQL Server:
Count = 0
Do While Not Result.EOF
Referring(Count) = Result.Fields(1)
Referring_Name(Count) = Result.Fields(0)
Result.MoveNext
Count=Count+1
LOOP
The bold sections seem to be where you can reference the value or name of a recordset field in SQL Server. Perhaps there is a different method for Access? -
WSsteve_skelton13
AskWoody LoungerMay 2, 2003 at 1:23 pm in reply to: Mystery! Sum in Query not working (Access 2000 Win 2000 SR-1) #673055I’m not terribly worried about getting Nulls back in as the db will only be accessed from a web form — and every time a new record is created (via INSERT) 0’s will be put in all the appropriate fields. obviously, *I* could muck things up during development but once it’s in production db interaction will be limited to report generation and archiving out old data. Unless the form itself changes and data elements get changed or removed.
I do find it a little odd that SUM doesn’t function if there are null values in fields. How can Null ever be counted in a sum? Also, the problem seems more persistent when field type is set to Numeric. I have some other fields that may or may not have null values but SUM seems to work with a number in a column and the field type set to text. It’s a little hard to test because you can’t tell by looking if a cell is Null or simply blank.
-
WSsteve_skelton13
AskWoody LoungerMay 1, 2003 at 8:56 pm in reply to: Mystery! Sum in Query not working (Access 2000 Win 2000 SR-1) #672789the table was also changed to make the data number type with default to 0 so all new data will not be null. “” I suppose.
-
WSsteve_skelton13
AskWoody LoungerMay 1, 2003 at 3:03 pm in reply to: Mystery! Sum in Query not working (Access 2000 Win 2000 SR-1) #672682thanks for the reply. yes, that seems to be the problem. i went to the source table and added zeros and now the second sum query works. huh! pesky nulls.
-
WSsteve_skelton13
AskWoody Loungeri don’t think that’ll work, simply because radio buttons are like checkboxes: unless they are checked, no value is passed and you can’t validate for them. I tried to do this using the following code: document.form.radio(20).checked != True and nothing happened. perhaps I am missing something here as in the right way to reference a form element in the DOM syntax.
in this case, I don’t want to set a default. but, I thought this would be a problem and I told the person requesting this functionality that it might not be possible. i suppose this makes sense: like checkboxes, radio buttons represent optional data and you’d expect that sometimes a user wouldn’t need to select one. If I replace the data element with a drop-down box I have to set a default value anyway as drop-downs don’t permit a blank value as a default. so, I just put in a test line in the preview.asp page to notify the user that they have not indicated a Yes or No on the question. For my purposes, this also works.
BTW, is there an issue using more than one javascript function for ONSUBMIT? I find that the validation code doesn’t fire if I put more than one ONSUBMIT parameter in the block.
-
WSsteve_skelton13
AskWoody Loungerthanks. CDate did the trick!
-
WSsteve_skelton13
AskWoody Loungerthere is also this excellent tool:
http://bobby.watchfire.com/bobby/html/en/index.jsp%5B/url%5D
for examining your site for disability compatibilities. for those of you working on a development webserver with no ‘real’ internet presence, they provide a java app that allows you to scan and evaluate local pages.
-
WSsteve_skelton13
AskWoody Loungerboy this is an old thread! i can’t even find the project i was working on that spawned the original inquiry and the whole issue is basically moribund for me. if memory serves, I didn’t like the nag screens and decided the added help file wasn’t going to be as helpful as i thought so just dropped the whole thing.
-
WSsteve_skelton13
AskWoody Loungerworked perfectly! thanks.
don’t know why but i do enjoy this sort of thing. must have gotten dropped on my head when young…
-
WSsteve_skelton13
AskWoody LoungerI got this hint about using the code &H00000080 instead of a ADOVBS.INC derived named constant from this excellent article from an excellent resource:
http://www.aspfaq.com/show.asp?id=2191%5B/url%5D
Using the constant rather than rhe named argument adExecuteNoRecords means you don’t need to append the include file and that reduces overhead by some small amount. In my case, I am implementing a series of web-based forms and may have to do several reads/writes to a (yecch) ACCESS database, so I am concerned with making the code as lean as possible and keep overhead in page processing low. I don’t know if there’s much of a problem with the include file but, all things considered, if you don’t need a lot of named constants to maintain a page, I don’t see why you shouldn’t use the direct constant. You can always put in a comment line defining what the constant does. It’s a programming style issue, ultimately.
I tend to agree with the preference to use the ADOVBS file rather than msoado15.dll in terms of how much control you have over the public webserver. in my case, I have no control over it and the people that do took 3 weeks to reinstall and configure CDONTS on the box after a serious crash. don’t want to rely on them to set up anything customizeable for my needs. So, DNS-less connections certainly, and ADOVBS.INC if necessary.
Oh, and also: I was very happy to fun into the http://www.aspfaq.com[/url%5D site as the person running it does a great job in discussing ASP problems and solutions and, better still, hasn’t cluttered things up with buzzwordy ASP.NET articles that are useless for my needs. check it out!
-
WSsteve_skelton13
AskWoody LoungerI don’t use an include in this case as the db is specific to the task at hand, but I don’t think that’s much of an issue. I think the .asp page must be corrupted in some way. Here’s what I’ve done since last posting:
Created a new page with just the connection information to open the target db, read and print a single field. It works. The original, bad, page, bombs using good connection strings. both the new good .asp and the old bad .asp pages are in the same folder. perhaps something in the rest of the coding is causing a problem, but i don’t see how as the .asp should process in order of the file itself.
Well, now that I have a .asp page that actually finds, opens and reads from the db in the MDB folder, I will start porting in the rest of the code and keep testing.
new information
I found the offending code: DataConnection.execute(mySQL)
I can open, read and print data from the mdb but when .asp tries to run the above code it fails with the usual errors. Obviously this isn’t working but not sure what to use to run the INSERT SQL string. any suggestions?
PROGRESS
‘peers that I needed to set read/write permission to the Access file to get it to update. I am now inserting willy-nilly. On to fine-tuning an attempt to dynamically create valid SQL strings… The Dataconnection.execute is not offensive and, from another web page I got this:
DataConnection.execute mySQL, , &H00000080 which works — the bit of coding at the end is a way to specify a record insert without having to declare DataConnection.AddNew & is supposed to be faster than relying on Command coding or the ADOVBS.INC file.
-
WSsteve_skelton13
AskWoody LoungerThe suggested change on the DataConnection string makes no difference. There seems to be something wrong with the .asp page itself. I have other pages that use the DataConnection string with the ‘bad’ slash usage and I am getting smooth connections and reads from .mdb files in the same folder. Stranger still, if i copy the code connection block from a working .asp page into the one I am trying to cure, I get the same error message looking for the .mdb file in the path C:WINNTsystem32 — so .asp connect works perfectly in one folder on the web server and gives me errors in another folder. both folders are set in IIS to allow script address and are assigned as application nodes.
What in the world is going on?? I checked page options and both Good .asp page and Bad .asp pages are exactly the same. .asp almost seems like it is trying to find a System DSN. Strange. I am stuck at this point and can’t test for successful INSERTS to a db that refuses to be found or, if you go ahead and put it where the system insists on looking for it, it can’t be opened.
sigh…
as to the other problem with some code working on one page but not on another: my bad! I forgot to embed the code in a loop so it wasn’t exactly the same and was working fine, in the sense of not doing anything at all. programming in the evening can be dangerous.
-
WSsteve_skelton13
AskWoody Loungeraha! makes sense. now i have to do a lot of clicking but c’est la vie.. or, as they say *these* days, c’est la guerre [may be mispelled there]
-
WSsteve_skelton13
AskWoody LoungerI could but it’d be boring. I have a table with various checkboxes such as:
Private Organization
Just generic checkbox, input boxs, drop-down boxes, etc. Furthermore, I have a dynamically-generated table on another page that writes a table base on the number of lines needed to input and the form elements are auto-named with .asp so I can’t rely on any hard-coding for that part at least. (actually the .asp code I discussed in the first post does find and list the items in the dynamic table, but there are no checkboxes in it…)
The crux of the matter is this: the code
<%
For Each item In Request.Form
Response.Write(item) & "”
Next
%>Finds and lists the NAMES of drop-downs, text boxes and submit/reset buttons but NOT checkboxes. The html code for a textbox is:
the html for a checkbox is:
Private Organization
Why my little asp loop skips the checkbox input type is the mystery. I’m thinking there’s some kind of keyword to make asp find checkboxes.
-
WSsteve_skelton13
AskWoody LoungerMarch 14, 2003 at 8:20 pm in reply to: Using an Array for a File Rename (Office 2000 SR-1, Excel2000) #661254thanks – worked beautifully.
![]() |
Patch reliability is unclear. Unless you have an immediate, pressing need to install a specific patch, don't do it. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
Does windows update component store “self heal”?
by
Mike Cross
48 minutes ago -
Windows 11 Insider Preview build 27858 released to Canary
by
joep517
1 hour, 48 minutes ago -
Pwn2Own Berlin 2025: Day One Results
by
Alex5723
1 hour, 14 minutes ago -
Windows 10 might repeatedly display the BitLocker recovery screen at startup
by
Susan Bradley
1 hour, 55 minutes ago -
Windows 11 Insider Preview Build 22631.5409 (23H2) released to Release Preview
by
joep517
4 hours, 30 minutes ago -
Windows 10 Build 19045.5912 (22H2) to Release Preview Channel
by
joep517
4 hours, 32 minutes ago -
Kevin Beaumont on Microsoft Recall
by
Susan Bradley
11 hours, 33 minutes ago -
The Surface Laptop Studio 2 is no longer being manufactured
by
Alex5723
12 hours, 39 minutes ago -
0Patch, where to begin
by
cassel23
6 hours, 41 minutes ago -
CFPB Quietly Kills Rule to Shield Americans From Data Brokers
by
Alex5723
1 day, 2 hours ago -
89 million Steam account details just got leaked,
by
Alex5723
14 hours, 2 minutes ago -
KB5058405: Linux – Windows dual boot SBAT bug, resolved with May 2025 update
by
Alex5723
1 day, 10 hours ago -
A Validation (were one needed) of Prudent Patching
by
Nibbled To Death By Ducks
1 day, 1 hour ago -
Master Patch Listing for May 13, 2025
by
Susan Bradley
12 hours, 56 minutes ago -
Installer program can’t read my registry
by
Peobody
7 hours, 54 minutes ago -
How to keep Outlook (new) in off position for Windows 11
by
EspressoWillie
23 hours, 36 minutes ago -
Intel : CVE-2024-45332, CVE-2024-43420, CVE-2025-20623
by
Alex5723
1 day, 6 hours ago -
False error message from eMClient
by
WSSebastian42
1 day, 21 hours ago -
Awoke to a rebooted Mac (crashed?)
by
rebop2020
2 days, 7 hours ago -
Office 2021 Perpetual for Mac
by
rebop2020
2 days, 8 hours ago -
AutoSave is for Microsoft, not for you
by
Will Fastie
1 day, 4 hours ago -
Difface : Reconstruction of 3D Human Facial Images from DNA Sequence
by
Alex5723
2 days, 11 hours ago -
Seven things we learned from WhatsApp vs. NSO Group spyware lawsuit
by
Alex5723
1 day, 12 hours ago -
Outdated Laptop
by
jdamkeene
2 days, 17 hours ago -
Updating Keepass2Android
by
CBFPD-Chief115
2 days, 22 hours ago -
Another big Microsoft layoff
by
Charlie
2 days, 22 hours ago -
PowerShell to detect NPU – Testers Needed
by
RetiredGeek
25 minutes ago -
May 2025 updates are out
by
Susan Bradley
2 hours, 7 minutes ago -
Windows 11 Insider Preview build 26200.5600 released to DEV
by
joep517
3 days, 4 hours ago -
Windows 11 Insider Preview build 26120.3964 (24H2) released to BETA
by
joep517
3 days, 4 hours ago
Recent blog posts
Key Links
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.