Abhishek
Abhishek

Reputation: 299

meaning of these lines of code

I am converting Visual Basic 6.0 code to .NET 4.5. I have the following lines of code. Can you tell me what they mean?

SQLMappingTables = " SELECT * FROM MappingTables " & _
                    " WHERE  Group_Level = ? " & _
                    "    AND Group_Code  = ? " & _
                    "    AND Code = ? " 
Set Cmd_MappingTables = New ADODB.Command
Cmd_MappingTables.CommandText = SQLMappingTables
Cmd_MappingTables.CommandType = adCmdText
/// These are the line I do not understand
Set DefGroup_Level = Cmd_MappingTables.CreateParameter(, adChar, adParamInput, 1)
Set DefGroup_Code = Cmd_MappingTables.CreateParameter(, adChar, adParamInput, 15)
Set DefCode8 = Cmd_MappingTables.CreateParameter(, adChar, adParamInput, 3)

Upvotes: 0

Views: 66

Answers (1)

Klas Lindbäck
Klas Lindbäck

Reputation: 33273

It defines three unnamed (first parameter left out) string (adChar) input parameters (adParamInput) of length 1, 15 and 3.

You can find a description here.

I would expect the subsequent lines to assign values to the input parameters, before the command is executed.

Upvotes: 1

Related Questions