Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
 
Posts: n/a
Default First row in Selection range (first index of a cell) EXCEL VBA

Hello,
I have a problem with selecting first cel in selection Range or return
an index of the first cell in Selection Cell.

I have something like this (VBA Code):
....................
Range1.Select
"and here I want to Select the first range in selection Range1"
.............
I there any special function of finding first cell in selection range
or returning an index of the first cell??
Thanks for answet
Marcin

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Kevin Vaughn
 
Posts: n/a
Default First row in Selection range (first index of a cell) EXCEL VBA

You want the first cell in the range? You can use .range("a1") of the range.
Here is a short example:

Sub TestRange()
Dim rng As Range
Set rng = Range("a1", "d10")
Debug.Print rng.Address
Debug.Print rng.Range("a1").Address
End Sub

In the Immediate window shows:
$A$1:$D$10
$A$1
Is that what you wanted?
--
Kevin Vaughn


" wrote:

Hello,
I have a problem with selecting first cel in selection Range or return
an index of the first cell in Selection Cell.

I have something like this (VBA Code):
....................
Range1.Select
"and here I want to Select the first range in selection Range1"
.............
I there any special function of finding first cell in selection range
or returning an index of the first cell??
Thanks for answet
Marcin


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
How can I display a cell range in a text box in excel? Pat Hughes Excel Discussion (Misc queries) 3 September 22nd 05 05:13 PM
Possible Lookup Table Karen Excel Worksheet Functions 5 June 8th 05 09:43 PM
Cell range in Excel Joe Sadusky Excel Discussion (Misc queries) 1 January 16th 05 01:14 AM
Excel: How to return count for each cell within date range criter. Louisa Excel Worksheet Functions 0 November 5th 04 11:58 AM
index to a range of cells Frank Kabel Excel Worksheet Functions 0 October 27th 04 05:39 PM


All times are GMT +1. The time now is 10:22 PM.

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"