Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Looking ior the commnds for several things....

I would like to know how to move the:
First record (disregarding filter settings ]) would this be some thing like
activecell(-row(),0)

First VISIBLE record

Last record (disregarding filter settings)
Last VISIBLE record

I want these setting for my nav bar.

Would I hen ge something like
set rMarker to firstrow() ' or what ever command that you tell me...)
activecell(rMarker,0)

The next/prev I have hammered out and it works fine

How do I use the SCROLL bar to move to a given record, and how do I update
the scrollbar?
I have the SCROLLBAR working for the next/prev. If it filter is in place amd
I do NOT what to see hidde, then I update the varible plus or minus 1 for
each time I press the up/down (and test for <1 and greater than record
count) and if filter, then ONLY when the keys are pressed AND record is not
hidden.
I need to find out what the current record postion I am on currently



How do I get the record or record when aq FILTER is set?
I know there is a command that will give me the count of visible rows, how
do I do this?

Thanks

I know these are basic questions, but I have not been able to find the
answers in any of my books, or the web (I KNOW it is there...)




  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Looking ior the commnds for several things....

Assume your data is in a named range Database

Sub FirstRecord()
Range("Database").Rows(2).Select
End Sub

Sub LastRecord()
Dim rng As Range
Set rng = Range("Database")
rng.Rows(rng.Rows.Count).Select
End Sub

Sub FirstVisibleRecord()
Dim rng As Range, rng1 As Range
Dim rng2 As Range
Set rng = Range("Database")
Set rng1 = rng.Offset(1, 0).Resize(rng.Rows.Count - 1)
On Error Resume Next
Set rng2 = rng1.SpecialCells(xlVisible)
On Error GoTo 0
If Not rng2 Is Nothing Then
rng2.Areas(1).Rows(1).Select
End If
End Sub

Sub LastVisibleRecord()
Dim rng As Range, rng1 As Range
Dim rng2 As Range, rng3 As Range
Set rng = Range("Database")
Set rng1 = rng.Offset(1, 0).Resize(rng.Rows.Count - 1)
On Error Resume Next
Set rng2 = rng1.SpecialCells(xlVisible)
On Error GoTo 0
If Not rng2 Is Nothing Then
Set rng3 = rng2.Areas(rng2.Areas.Count)
rng3.Rows(rng3.Rows.Count).Select
End If
End Sub


--
Regards,
Tom Ogilvy




Phillips wrote in message
news:frPIb.702592$HS4.5032663@attbi_s01...
I would like to know how to move the:
First record (disregarding filter settings ]) would this be some thing

like
activecell(-row(),0)

First VISIBLE record

Last record (disregarding filter settings)
Last VISIBLE record

I want these setting for my nav bar.

Would I hen ge something like
set rMarker to firstrow() ' or what ever command that you tell me...)
activecell(rMarker,0)

The next/prev I have hammered out and it works fine

How do I use the SCROLL bar to move to a given record, and how do I update
the scrollbar?
I have the SCROLLBAR working for the next/prev. If it filter is in place

amd
I do NOT what to see hidde, then I update the varible plus or minus 1 for
each time I press the up/down (and test for <1 and greater than record
count) and if filter, then ONLY when the keys are pressed AND record is

not
hidden.
I need to find out what the current record postion I am on currently



How do I get the record or record when aq FILTER is set?
I know there is a command that will give me the count of visible rows, how
do I do this?

Thanks

I know these are basic questions, but I have not been able to find the
answers in any of my books, or the web (I KNOW it is there...)






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
Things to do with the cells DDD Excel Discussion (Misc queries) 1 December 8th 08 01:05 AM
A few things Bryan De-Lara[_2_] Excel Worksheet Functions 6 November 3rd 08 04:58 PM
Top 10 Things To Look For In A Web Host best_hosting Excel Worksheet Functions 0 September 14th 08 03:01 PM
how to do these things in Excel with and without VBA? LunaMoon Excel Discussion (Misc queries) 11 July 10th 08 08:19 PM
######THEY DO DIFFERENT THINGS TO GET IT############# keerthi Charts and Charting in Excel 0 April 30th 08 07:45 AM


All times are GMT +1. The time now is 07:12 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"