convert string to type for cmd parameter

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • MATTXtwo
    New Member
    • Sep 2006
    • 83

    convert string to type for cmd parameter

    hi guys got in pinch here...
    Code:
    rz.Parameters.Append rz.CreateParameter("@OldAccNo",adDecimal,adParamInput,9,OldAccNo)
    rz.Parameters.Append rz.CreateParameter("@NewAccNo",adChar,adParamInput,11,NewAccNo)
    rz.Parameters.Append rz.CreateParameter("@RewardNo",adVarChar,adParamInput,15,RewardNo)
    rz.Parameters.Append rz.CreateParameter("@NewICNo",adChar,adParamInput,12,NewICNo)
    rz.Parameters.Append rz.CreateParameter("@Amounts",adCurrency,adParamInput,,Amounts)
    rz.Parameters.Append rz.CreateParameter("@TransDate",adDate,adParamInput,,TransDate)
    rz.Parameters.Append rz.CreateParameter("@ReceiptNo",adNumeric,adParamInput,15,ReceiptNo)
    rz.Parameters.Append rz.CreateParameter("@POCode",adVarChar,adParamInput,5,POCode)
    I need to change all the parameter value from (current)String to selected data type...any ideas
  • iam_clint
    Recognized Expert Top Contributor
    • Jul 2006
    • 1207

    #2
    i'm really not sure what you are asking here?

    Do you mean like
    Code:
    dim test
    test="1" 'this is a string obviously
    test=cint(test) 'this converts it to an int
    I need more detail on what you are doing and for cmd I am assuming for adodb command?

    Comment

    Working...