Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.access.modulesdaovba,microsoft.public.excel.programming
JH JH is offline
external usenet poster
 
Posts: 64
Default "Cannot expand named range"

I have a process that I support that has started generating an error.

This process imports a spreadsheet from Excel into Access. It then runs
queries to split the data into individual accounts and then it exports the
split up data back to Excel using the following command:

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel3, "Temp55a",
strLoc, True

83 Spreadsheets of 86 get created.
The 84th spreadsheet fails with error number 3434 - Cannot expand named range.
Once the error is encountered the database closes with the process unfinished.

I am completely baffled by this. There is NO named range in the command.

The parameters break down to action type (acExport), Excel version
(acSpreadsheetTypeExcel3), Access table name (Temp55a), File Name (strLoc),
Column headings (True).

I have searched extensively trying to find an answer to this issue with no
luck. In fact, I have not even seen anyone else having a similar issue.

Any help would be greatly appreciated.
  #2   Report Post  
Posted to microsoft.public.access.modulesdaovba,microsoft.public.excel.programming
external usenet poster
 
Posts: 133
Default "Cannot expand named range"

Just a thought: there isn't a blank row in the data being exported is there?
Excel may be creating a hidden name for the imported data that isn't being
addressed properly (as you probably know, not being a database package -
despite being used far too much as one! - Excel cannot understand lists with
blank rows).

"JH" wrote:

I have a process that I support that has started generating an error.

This process imports a spreadsheet from Excel into Access. It then runs
queries to split the data into individual accounts and then it exports the
split up data back to Excel using the following command:

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel3, "Temp55a",
strLoc, True

83 Spreadsheets of 86 get created.
The 84th spreadsheet fails with error number 3434 - Cannot expand named range.
Once the error is encountered the database closes with the process unfinished.

I am completely baffled by this. There is NO named range in the command.

The parameters break down to action type (acExport), Excel version
(acSpreadsheetTypeExcel3), Access table name (Temp55a), File Name (strLoc),
Column headings (True).

I have searched extensively trying to find an answer to this issue with no
luck. In fact, I have not even seen anyone else having a similar issue.

Any help would be greatly appreciated.

  #3   Report Post  
Posted to microsoft.public.access.modulesdaovba,microsoft.public.excel.programming
JH JH is offline
external usenet poster
 
Posts: 64
Default "Cannot expand named range"

No. There are no blank rows in the Access table that is being exported.

Any other ideas?

"Smallweed" wrote:

Just a thought: there isn't a blank row in the data being exported is there?
Excel may be creating a hidden name for the imported data that isn't being
addressed properly (as you probably know, not being a database package -
despite being used far too much as one! - Excel cannot understand lists with
blank rows).

"JH" wrote:

I have a process that I support that has started generating an error.

This process imports a spreadsheet from Excel into Access. It then runs
queries to split the data into individual accounts and then it exports the
split up data back to Excel using the following command:

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel3, "Temp55a",
strLoc, True

83 Spreadsheets of 86 get created.
The 84th spreadsheet fails with error number 3434 - Cannot expand named range.
Once the error is encountered the database closes with the process unfinished.

I am completely baffled by this. There is NO named range in the command.

The parameters break down to action type (acExport), Excel version
(acSpreadsheetTypeExcel3), Access table name (Temp55a), File Name (strLoc),
Column headings (True).

I have searched extensively trying to find an answer to this issue with no
luck. In fact, I have not even seen anyone else having a similar issue.

Any help would be greatly appreciated.

  #4   Report Post  
Posted to microsoft.public.access.modulesdaovba,microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default "Cannot expand named range"

acSpreadsheetTypeExcel3 is way out of date. I don't know what version of
Excel you are using, but since 2000, it has been acSpreadsheetTypeExcel9. I
have heard of other problems using the same code. I would suggest you either
align your code to reference the version of Excel you are using or leave it
blank at 9 will be used by Default.
--
Dave Hargis, Microsoft Access MVP


"JH" wrote:

No. There are no blank rows in the Access table that is being exported.

Any other ideas?

"Smallweed" wrote:

Just a thought: there isn't a blank row in the data being exported is there?
Excel may be creating a hidden name for the imported data that isn't being
addressed properly (as you probably know, not being a database package -
despite being used far too much as one! - Excel cannot understand lists with
blank rows).

"JH" wrote:

I have a process that I support that has started generating an error.

This process imports a spreadsheet from Excel into Access. It then runs
queries to split the data into individual accounts and then it exports the
split up data back to Excel using the following command:

DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel3, "Temp55a",
strLoc, True

83 Spreadsheets of 86 get created.
The 84th spreadsheet fails with error number 3434 - Cannot expand named range.
Once the error is encountered the database closes with the process unfinished.

I am completely baffled by this. There is NO named range in the command.

The parameters break down to action type (acExport), Excel version
(acSpreadsheetTypeExcel3), Access table name (Temp55a), File Name (strLoc),
Column headings (True).

I have searched extensively trying to find an answer to this issue with no
luck. In fact, I have not even seen anyone else having a similar issue.

Any help would be greatly appreciated.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
combining values and text to make a reference for "named range" devo.uk Excel Worksheet Functions 4 June 10th 08 10:31 AM
Array as a "named range" - formula ok in cells, but error as "named range" tskogstrom Excel Discussion (Misc queries) 11 December 28th 06 04:44 PM
macro to remove a named range always called "database" & if possib Todd F.[_2_] Excel Programming 9 July 25th 05 06:25 PM
Listbox "expand range as list grows" TK Excel Programming 3 September 8th 04 11:57 PM
Adding named range gives error "method range of object _Global failed " Gunnar Johansson Excel Programming 3 August 10th 04 01:54 PM


All times are GMT +1. The time now is 04:28 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"