Results 1 to 3 of 3

Thread: Connection String Data source

  1. #1

    Connection String Data source

    Register for a FREE account, and/
    or Log in to avoid these ads!

    Connection String Data source=Z:\myfolder\data\abc.xlsx

    How to edit the connection string, so that I can connect the abc.xlsx at the current direction and ignore the physical path.
    Expected connection path: Connection String Data source=abc.xlsx
    I tried above, but failed.

  2. #2
    Super Moderator Bob Phillips's Avatar
    Join Date
    Mar 2011
    Excel Version
    Would it be

    "Data Source=" & Thisworkbook.Path & Application.PathSeparatoor & "abc.xlsx"

  3. #3
    Hi Bob, thanks for advice.
    I tried but failed. Pls clarify if "PathSeparatoor" is typo mistake? should be "PathSeparator" ?
    Anyway, I try both spelling but failed too.
    pls refer to my screendump where I try to edit.
    Click image for larger version. 

Name:	data_source.jpg 
Views:	20 
Size:	71.1 KB 
ID:	1102

Posting Permissions

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