■ 파라미터 추가하기

----------------------------------------------------------------------------------------------------

Public Function AddParameter(pCommand As ADODB.Command, strParameterName As String, pDataType As DataTypeEnum, pParameterDirection As ParameterDirectionEnum, pSize As ADO_LONGPTR) As ADODB.Parameter

 

    Dim pParameter As ADODB.Parameter

    

    Set AddParameter = Nothing

    

    On Error GoTo ErrorLabel

    

    Set pParameter = pCommand.CreateParameter(strParameterName, pDataType, pParameterDirection, pSize)

 

    pCommand.Parameters.Append pParameter

    

    Set AddParameter = pParameter

    

    Exit Function

    

ErrorLabel:

 

End Function

----------------------------------------------------------------------------------------------------

Posted by 사용자 icodebroker

댓글을 달아 주세요