![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Mar 2002
Posts: 37
|
Is there an easier way to get the A & 1 from an address of an active cell, without parsing it? Or is there a way to check if the active cell in a column is the next cell below the last cell with data in it?
Thanks |
|
|
|
|
|
#2 | |
|
Guest
Posts: n/a
|
Quote:
ActiveCell.Row ActiveCell.Column to check whether the activecell is in the position you state try this:- Code:
Sub IsActiveCellLastCell()
If Cells(65536, ActiveCell.Column).End(xlUp).Row = ActiveCell.Row - 1 Then
MsgBox "Active cell is in next available cell in column"
Else
MsgBox "Active cell is not in next available cell in column"
End If
End Sub
D |
|
|
|
|
#3 |
|
Banned
Join Date: Feb 2002
Posts: 1,582
|
Hi John
You could get the Column letter like: Dim strCol As String strCol = ActiveCell.EntireColumn.Address(ColumnAbsolute:=False) strCol = Left(strCol, InStr(1, strCol, ":", vbTextCompare) - 1) MsgBox strCol |
|
|
|
|
|
#4 |
|
New Member
Join Date: Mar 2002
Posts: 37
|
Dave & Anonymous,
Thanks for your tips. After looking at them, they cleared up alot. Thanks again, John |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|