If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
error 3001 in data access page
Hi all,
I have a DAP off of a table, that i added a search button to (code from microsoft, see below) This works fine for the 1st DAP i did. SCRIPT language=vbscript event=onclick for=search !-- 'Clone the recordset. Dim rs Set rs = MSODSC.DataPages(0).Recordset.Clone On error resume next ' rs.find "TLAUnit" & cLng(inputbox("Enter SN","Find")) rs.find "TLAUnit='" & CStr(InputBox("Enter Unit S/N", "Find")) & "'" If (err.number 0) Then Msgbox "Error: " & err.number & " " & err.Description, , "Invalid Search" Exit Sub End If 'Check search results for Success. If (rs.bof) or (rs.eof) then Msgbox "No SN found",,"Search Done" Exit Sub End if MSODSC.DataPages(0).Recordset.Bookmark = rs.Bookmark -- I created a 2nd DAP off of another table and added the same code, replaceing "TLAUnit" with "SLA front" When i enter search criteria for this 2nd DAP I get an error: ERROR 3001:Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another. Any Ideas? Kevin |
#2
|
|||
|
|||
I figured it out
had to have "TLAUnit='" read "[TLAUnit]='" "krberube" wrote: Hi all, I have a DAP off of a table, that i added a search button to (code from microsoft, see below) This works fine for the 1st DAP i did. SCRIPT language=vbscript event=onclick for=search !-- 'Clone the recordset. Dim rs Set rs = MSODSC.DataPages(0).Recordset.Clone On error resume next ' rs.find "TLAUnit" & cLng(inputbox("Enter SN","Find")) rs.find "TLAUnit='" & CStr(InputBox("Enter Unit S/N", "Find")) & "'" If (err.number 0) Then Msgbox "Error: " & err.number & " " & err.Description, , "Invalid Search" Exit Sub End If 'Check search results for Success. If (rs.bof) or (rs.eof) then Msgbox "No SN found",,"Search Done" Exit Sub End if MSODSC.DataPages(0).Recordset.Bookmark = rs.Bookmark -- I created a 2nd DAP off of another table and added the same code, replaceing "TLAUnit" with "SLA front" When i enter search criteria for this 2nd DAP I get an error: ERROR 3001:Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another. Any Ideas? Kevin |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
The data definition of this data access page has been corrupted a. | mobydick86 | General Discussion | 1 | December 30th, 2004 07:01 PM |
printing data access page | Mark Alejandro | General Discussion | 0 | November 10th, 2004 07:20 PM |
Adding staff photographs to my database | KK | New Users | 2 | September 3rd, 2004 07:41 AM |
Problem creating a Data Access page | Ron | General Discussion | 0 | June 28th, 2004 09:30 PM |
Data Access Page Problem | Doug Munich | General Discussion | 0 | June 5th, 2004 12:03 AM |