LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
Ben Ben is offline
external usenet poster
 
Posts: 509
Default extending excel named range with vba

ActiveWorkbook.Names.Add Name:="hello", RefersToR1C1:="=Sheet1!R66C32:R67C40"

where "hello" is the name of the range
and Sheet1 is the nanme of the sheet.
this will overwrite any existing range so do not worry about having to
modify it

R66C32 = upper left bound of range. R67C40 = lower right bound
substitute rows and columns as needed
"Hugo & Monique" wrote:

Hi,

I am trying to resize a named range (extracted from a database) according to
the actual number of rows which varies each time I dump records from that
database.
Since I don't want to do this manually each time, I would like to automate
this task. Can someone give me a hint on how this can be done in VBA ?

Thank you !

Monique
Belgium



 
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
extending named ranges chrisbmo2000 Excel Discussion (Misc queries) 2 May 5th 08 12:12 PM
Extending a range Macca1984 Excel Discussion (Misc queries) 5 March 6th 08 11:36 AM
Extending Sort Range Millington Excel Worksheet Functions 0 October 14th 07 03:24 PM
Extending Named Ranges [email protected] Excel Programming 4 September 25th 04 04:37 PM


All times are GMT +1. The time now is 02:18 PM.

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

About Us

"It's about Microsoft Excel"