Page 2 of 2 FirstFirst 12
Results 16 to 19 of 19
  1. #16
    WS Lounge VIP access-mdb's Avatar
    Join Date
    Dec 2009
    Location
    Oxfordshire, UK
    Posts
    2,152
    Thanks
    177
    Thanked 214 Times in 202 Posts
    Dave, had you closed the Spreadsheet before you did the import? When I tried with my simple experiment it couldn't find the named range until I had. Though I can't remember what error message it came up with. As I said before, I'm not familiar with named ranges.....

    Just looking again, mine wasn't dynamic, so my comment above may not be valid. However, on your last attachment, you seem to be linking rather than importing - is that significant?
    Last edited by access-mdb; 2019-01-14 at 03:57. Reason: added more info
    Cartophilia rocks

  2. #17
    New Lounger
    Join Date
    Jan 2019
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hello Malcolm,

    True, I am linking. As you guessed, the dynamic one is the named range causing the issue. I've done the straight static named range you recommended, and it works fine regardless of link / import. That is what I am working with for now until I find time to figure out the dynamic method.

    Cheers,
    Dave

  3. #18
    Super Moderator RetiredGeek's Avatar
    Join Date
    Mar 2004
    Location
    Manning, South Carolina
    Posts
    10,155
    Thanks
    448
    Thanked 1,653 Times in 1,487 Posts
    Dave,

    Ok, I genned up a test and here is what I found.

    Importing a Dynamic Range Name works. However, it did NOT respect the max number of columns. I had specified 3 columns but had data, no header, in column 4 and it imported it. Of course during the import process you can specify that it not be imported via a check box.

    UnWantedColumn.JPG

    Linking a Dynamic Range Name does not work for .xlsx files! However, it will work with .xls files, go figure! Of course it also did not respect the 3 column limit and the linking process does not give you the option of excluding columns! To remove unwanted columns you either have to alter the source Excel file or view the DB via a Query that only includes the desired columns.

    HTH
    May the Forces of good computing be with you!

    RG
    (still RetiredGeek on AskWoody.com)

    PowerShell & VBA Rule!

    My Systems: Desktop Specs
    Laptop Specs

  4. The Following User Says Thank You to RetiredGeek For This Useful Post:

    Lugh (2019-01-15)

  5. #19
    New Lounger
    Join Date
    Jan 2019
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks for the test RG.

    Unfortunately, I could not do a straight import of the dynamic name range from an xls either. Odd behaviour from both programs to not work a little more seamlessly.

    I'm also wondering if you folks see your additional sheets in the "show worksheet" or "show named ranges" section while importing. As I mentioned, Im seeing additional worksheets show up as named ranges.

Page 2 of 2 FirstFirst 12

Posting Permissions

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