Results 1 to 12 of 12

Thread: Syntax error (Resolved)

Hybrid View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jun 2005
    Posts
    16

    Re: Syntax error

    .Parameters.Append .CreateParameter("@DateFrom", adVarChar, adParamInput, 25, CStr(MyArgs(1)))
    .Parameters.Append .CreateParameter("@DateTo", adVarChar, adParamInput, 25, CStr(MyArgs(2)))

    'Setup connection details and open connection to dB
    Set mycon = New ADODB.Connection
    mycon.ConnectionString = "File Name=" & App.Path & UDL_FILENAME
    mycon.Open

    Set .ActiveConnection = mycon

    'Run command
    .Execute

    no matter how i pass these variables, i am getting the same error.
    i mean i tried with the parameter datatype as adDate. no luck
    I respect Faith, but doubts are what get me educated

  2. #2
    Software Carpenter dee-u's Avatar
    Join Date
    Feb 2005
    Location
    Pinas
    Posts
    11,127

    Re: Syntax error

    What is CStr(MyArgs(2))?
    Regards,


    As a gesture of gratitude please consider rating helpful posts. c",)

    Some stuffs: Mouse Hotkey | Compress file using SQL Server! | WPF - Rounded Combobox | WPF - Notify Icon and Balloon | NetVerser - a WPF chatting system

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width