Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Code does not work on sharepoint

Status
Not open for further replies.

Niebotel

Programmer
Jan 1, 2007
169
NL
I have the following code in my application; Now I Migrated the tables to a sharepoint and I get an unknown error on the last line:
I did create the code by copy and paste; I'm not an expert on it but it worked until now!

Public Function BepaalLidnummer()

Dim cmd As ADODB.Command
Dim rs As ADODB.Recordset
Dim Prm As ADODB.Parameter
Dim Postkod As String
Dim cmd2 As ADODB.Command
Dim rs2 As ADODB.Recordset
Dim Prm2 As ADODB.Parameter



Dim LidGevonden As Boolean, WachterGevonden As Boolean, strLidnum As String

'initialiseren indikatoren
LidGevonden = True
WachterGevonden = True

'4 linker cijfers gebruiken of anders 9999
If IsNumeric(Left(Forms![Wachters]![Postcode], 4)) = True Then
Postkod = Left(Forms![Wachters]![Postcode], 4) & "%"
Else
Postkod = "9999%"
End If

'Hoogste nummer ophalen uit leden
Set rs = New Recordset
Set cmd = New Command

cmd.ActiveConnection = CurrentProject.Connection

cmd.CommandText = "HoogsteLidnummerLeden" 'this is a query
Set Prm = cmd.CreateParameter
Prm.Type = adChar
Prm.Size = 25
cmd.Parameters.Append Prm

cmd.Parameters(0).Value = Postkod

rs.Open cmd, , adOpenForwardOnly, adLockReadOnly, adCmdStoredProc

Any suggestion how to solve?
Help will be appriciated very much!
 
do you mean that you migrated the tables to SharePoint lists?
If that is the case, you cannot interact with them as you would a normal database table. There is a whole api associated with SharePoint and list/library interaction.

carl
MCSD, MCTS:MOSS
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top