LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default How do I make references to cells in subroutines relative?

How do I make references to cells in subroutines relative?

For example, if part of my subroutine is:

Range("A5:D33").Select

then I insert or delete cells in the spreadsheet, the references to these
cells in the macro stay the same, and are thus incorrect. They always have to
be updated manually. How can I make these change automatically when I modify
the spreadsheet?

Or is there a better way to reference cells in the worksheet?

Thanks
Atreides
 
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
Naming Cells Using Relative Cell References Inobugs Excel Worksheet Functions 1 April 19th 09 03:50 PM
Help with converting a block of cells with Absolute and mixed references to relative references Vulcan Excel Worksheet Functions 3 December 13th 07 11:43 PM
Relative, absolute & mixed references in many cells FTM Excel Worksheet Functions 11 June 19th 06 09:38 AM
Module to make all absolute references relative Pro_D Mike Excel Programming 3 May 26th 06 06:41 PM
Using named cells in relative references rbekka33[_22_] Excel Programming 1 November 2nd 04 10:08 AM


All times are GMT +1. The time now is 05:13 AM.

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"