Is there a way to add new records to an intranet access database from a workstation access database.
I’m able to automatically download data from the intranet db when the workstation db opens using vba & asp examples that I found on the web.
I can’t figure out how to add records. Can someone point me in the right direction.
![]() |
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 |
-
Add records to a MS Access web database (2K)
Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Add records to a MS Access web database (2K)
- This topic has 16 replies, 3 voices, and was last updated 21 years, 5 months ago.
AuthorTopicWSready4data
AskWoody LoungerDecember 10, 2003 at 1:23 pm #397743Viewing 1 reply threadAuthorReplies-
WSDrew
AskWoody LoungerDecember 10, 2003 at 8:03 pm #755514I am assuming that you have the ability to create an asp page on the Intranet in question? The next question is are we talking about one record, or are we talking about a bunch of records. I ask, because if you are just pushing one record, and the data isn’t going to exceed a thousand (and change) characters, then you can just ‘open’ a link with the data in a querystring. But if you are pushing lots of records, you’ll need to ‘POST’ the data, through a form.
-
WSready4data
AskWoody LoungerDecember 10, 2003 at 8:25 pm #755532Drew,
I have control of the intranet server. The amount of data will vary depending on the user that connects. A bunch? Shouldn’t be more than 100 records at a time. Unfortunately ther are 86 fields in the table(not my design).You mention POST through a form. Is that in access or a web based form?
With the table info I gave you, let me know the best way.
Thanks -
WSDrew
AskWoody LoungerDecember 10, 2003 at 10:43 pm #755580Make a function that creates an HTML page with a form that posts the data that you want…
Function CreateHTMLForm()
Dim strTemp As String
Dim f As Long
Dim rs As Recordset
Dim strSQL as String
dim i as Long
Dim j as Long
strSQL=”SELECT * FROM MyTable”
set rs=CurrentDB.OpenRecordset(strSQL)
rs.MoveFirst
strTemp=”” & vbcrlf
j=0
Do Until rs.EOF=True
j=j+1
For i=0 to rs.Fields.Count
strTemp=strTemp & “” & vbcrlf
Next i
rs.MoveNext
Loop
rs.close
set rs=nothing
strTemp=strTemp & “” & vbcrlf & _
“” & vbcrlf & “” & vbcrlf & “EntryForm.submit” & vbcrlf & “” & vbcrlf & “”
f=FreeFile
Open “C:TempHTML.htm” for Binary Access Write As f
Put f,,strTemp
Close f
End FunctionNow you have to make an ASP page that will accept this data:
<%
Dim cnn
Dim rs
Dim i
Dim j
set cnn=server.createobject("ADODB.Connection")
set rs=server.createobject("ADODB.Recordset")
cnn.Provider="Microsoft.Jet.OLEDB.4.0"
cnn.Open "D:MyDB.mdb"
rs.Open "tblMyDataTable",cnn,1,3
For i=1 to request.form("RecordCount")
rs.AddNew
For j=0 to rs.Fields.Count
rs.Fields(j).value=request.form(rs.Fields(j).Name & i)
Next
rs.Update
Next
rs.close
set rs=nothing
cnn.close
set cnn=nothing
response.write "” & vbcrlf & “window.close” & vbcrlf & “” & vbcrlf
%>Then all you have to do, is launch the page in a browser, and it’ll do the rest.
-
WSClausParkhoi
AskWoody Lounger -
WSready4data
AskWoody LoungerDecember 11, 2003 at 11:24 am #755793Drew,
Thanks for the code. Claus I caught that mistake after the first run.
Drew I’m getting a page cannot be displaye in the browser(see pix).
The TempHTML.htm seems to be created ok.
I checked the table in the target db and all the fields are the same.
I caught the missing -1
What else can I check. I’m justarting to learn asp so bear with me.
Thanks,
Scott -
WSready4data
AskWoody Lounger -
WSDrew
AskWoody LoungerDecember 11, 2003 at 4:00 pm #755997That’s browser thing. http://forums.devshed.com/archive/1/2003/7/1/65501%5B/url%5D goes into it a bit, with a possible work around.
However, if you are launching the site with a custom browser, something you control as it is, then you can simply watch for the completion of the .asp page, and close the browser from the outside (like if you are using Automation with IE, or if you are using a webbrowser control from VB).
-
WSDrew
AskWoody LoungerDecember 11, 2003 at 4:00 pm #755998That’s browser thing. http://forums.devshed.com/archive/1/2003/7/1/65501%5B/url%5D goes into it a bit, with a possible work around.
However, if you are launching the site with a custom browser, something you control as it is, then you can simply watch for the completion of the .asp page, and close the browser from the outside (like if you are using Automation with IE, or if you are using a webbrowser control from VB).
-
WSready4data
AskWoody Lounger -
WSready4data
AskWoody LoungerDecember 11, 2003 at 11:24 am #755794Drew,
Thanks for the code. Claus I caught that mistake after the first run.
Drew I’m getting a page cannot be displaye in the browser(see pix).
The TempHTML.htm seems to be created ok.
I checked the table in the target db and all the fields are the same.
I caught the missing -1
What else can I check. I’m justarting to learn asp so bear with me.
Thanks,
Scott -
WSDrew
AskWoody Lounger -
WSDrew
AskWoody Lounger
-
-
WSClausParkhoi
AskWoody Lounger
-
-
WSDrew
AskWoody LoungerDecember 10, 2003 at 10:43 pm #755581Make a function that creates an HTML page with a form that posts the data that you want…
Function CreateHTMLForm()
Dim strTemp As String
Dim f As Long
Dim rs As Recordset
Dim strSQL as String
dim i as Long
Dim j as Long
strSQL=”SELECT * FROM MyTable”
set rs=CurrentDB.OpenRecordset(strSQL)
rs.MoveFirst
strTemp=”” & vbcrlf
j=0
Do Until rs.EOF=True
j=j+1
For i=0 to rs.Fields.Count
strTemp=strTemp & “” & vbcrlf
Next i
rs.MoveNext
Loop
rs.close
set rs=nothing
strTemp=strTemp & “” & vbcrlf & _
“” & vbcrlf & “” & vbcrlf & “EntryForm.submit” & vbcrlf & “” & vbcrlf & “”
f=FreeFile
Open “C:TempHTML.htm” for Binary Access Write As f
Put f,,strTemp
Close f
End FunctionNow you have to make an ASP page that will accept this data:
<%
Dim cnn
Dim rs
Dim i
Dim j
set cnn=server.createobject("ADODB.Connection")
set rs=server.createobject("ADODB.Recordset")
cnn.Provider="Microsoft.Jet.OLEDB.4.0"
cnn.Open "D:MyDB.mdb"
rs.Open "tblMyDataTable",cnn,1,3
For i=1 to request.form("RecordCount")
rs.AddNew
For j=0 to rs.Fields.Count
rs.Fields(j).value=request.form(rs.Fields(j).Name & i)
Next
rs.Update
Next
rs.close
set rs=nothing
cnn.close
set cnn=nothing
response.write "” & vbcrlf & “window.close” & vbcrlf & “” & vbcrlf
%>Then all you have to do, is launch the page in a browser, and it’ll do the rest.
-
-
WSready4data
AskWoody LoungerDecember 10, 2003 at 8:25 pm #755533Drew,
I have control of the intranet server. The amount of data will vary depending on the user that connects. A bunch? Shouldn’t be more than 100 records at a time. Unfortunately ther are 86 fields in the table(not my design).You mention POST through a form. Is that in access or a web based form?
With the table info I gave you, let me know the best way.
Thanks
-
-
WSDrew
AskWoody LoungerDecember 10, 2003 at 8:03 pm #755515I am assuming that you have the ability to create an asp page on the Intranet in question? The next question is are we talking about one record, or are we talking about a bunch of records. I ask, because if you are just pushing one record, and the data isn’t going to exceed a thousand (and change) characters, then you can just ‘open’ a link with the data in a querystring. But if you are pushing lots of records, you’ll need to ‘POST’ the data, through a form.
Viewing 1 reply thread -

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”? (Awaiting moderation)
by
Mike Cross
4 minutes ago -
Windows 11 Insider Preview build 27858 released to Canary
by
joep517
21 minutes ago -
Pwn2Own Berlin 2025: Day One Results
by
Alex5723
53 minutes ago -
Windows 10 might repeatedly display the BitLocker recovery screen at startup
by
Susan Bradley
28 minutes ago -
Windows 11 Insider Preview Build 22631.5409 (23H2) released to Release Preview
by
joep517
3 hours, 3 minutes ago -
Windows 10 Build 19045.5912 (22H2) to Release Preview Channel
by
joep517
3 hours, 4 minutes ago -
Kevin Beaumont on Microsoft Recall
by
Susan Bradley
10 hours, 5 minutes ago -
The Surface Laptop Studio 2 is no longer being manufactured
by
Alex5723
11 hours, 12 minutes ago -
0Patch, where to begin
by
cassel23
5 hours, 14 minutes ago -
CFPB Quietly Kills Rule to Shield Americans From Data Brokers
by
Alex5723
1 day ago -
89 million Steam account details just got leaked,
by
Alex5723
12 hours, 35 minutes ago -
KB5058405: Linux – Windows dual boot SBAT bug, resolved with May 2025 update
by
Alex5723
1 day, 9 hours ago -
A Validation (were one needed) of Prudent Patching
by
Nibbled To Death By Ducks
1 day ago -
Master Patch Listing for May 13, 2025
by
Susan Bradley
11 hours, 29 minutes ago -
Installer program can’t read my registry
by
Peobody
6 hours, 26 minutes ago -
How to keep Outlook (new) in off position for Windows 11
by
EspressoWillie
22 hours, 8 minutes ago -
Intel : CVE-2024-45332, CVE-2024-43420, CVE-2025-20623
by
Alex5723
1 day, 5 hours ago -
False error message from eMClient
by
WSSebastian42
1 day, 20 hours ago -
Awoke to a rebooted Mac (crashed?)
by
rebop2020
2 days, 5 hours ago -
Office 2021 Perpetual for Mac
by
rebop2020
2 days, 6 hours ago -
AutoSave is for Microsoft, not for you
by
Will Fastie
1 day, 3 hours ago -
Difface : Reconstruction of 3D Human Facial Images from DNA Sequence
by
Alex5723
2 days, 10 hours ago -
Seven things we learned from WhatsApp vs. NSO Group spyware lawsuit
by
Alex5723
1 day, 11 hours ago -
Outdated Laptop
by
jdamkeene
2 days, 15 hours ago -
Updating Keepass2Android
by
CBFPD-Chief115
2 days, 21 hours ago -
Another big Microsoft layoff
by
Charlie
2 days, 20 hours ago -
PowerShell to detect NPU – Testers Needed
by
RetiredGeek
18 hours, 13 minutes ago -
May 2025 updates are out
by
Susan Bradley
40 minutes ago -
Windows 11 Insider Preview build 26200.5600 released to DEV
by
joep517
3 days, 2 hours ago -
Windows 11 Insider Preview build 26120.3964 (24H2) released to BETA
by
joep517
3 days, 2 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.