Groups > WordPerfect Office > QuattroPro X3 > Re: hid rows




hid rows

hid rows
Mon, 7 Apr 2008 11:00:45 -0700
Hi all;
I have a Spreadsheet with many row of data, however some are blank.

With a macro, I would like to check a cell to see if is blank, then hide 
that row, if it is blank.

Thanks 


Post Reply
Re: hid rows
Mon, 7 Apr 2008 12:04:30 -0700
it will be many row that I need check, and hide.
"lemoto" <ctech@corel.ca> wrote in message 
news:VA.00004c00.004ef551@corel.ca...
>
> Fillmore:
>> With a macro, I would like to check a cell to see if is blank, then
hide
>> that row, if it is blank.
>>
> One row only? or a block/range?
> Using the current Cell? or a specified Col in the current Row?
> -- 
> Good wishes!
> Roy Lewis
> C_Tech volunteer
> (UK)
>
> 


Post Reply
Re: hid rows
Mon, 07 Apr 2008 13:41:19 -060
fillmore wrote:
> I have a Spreadsheet with many row of data, however some are blank.
> 
> With a macro, I would like to check a cell to see if is blank, then hide 
> that row, if it is blank.

QuickFilter does this for you:  simply apply the NonBlanks option.

Cheers,
Uli
Post Reply
Re: hid rows
Mon, 07 Apr 2008 19:57:36 GMT
Fillmore:
> With a macro, I would like to check a cell to see if is blank, then hide 
> that row, if it is blank.
>
One row only? or a block/range?
Using the current Cell? or a specified Col in the current Row?
-- 
Good wishes!
Roy Lewis
C_Tech volunteer
(UK)

Post Reply
Re: hid rows
Mon, 07 Apr 2008 20:27:27 GMT
Fillmore:
> it will be many row that I need check, and hide.

Preferably on a Sheet that is not a Sheet in which you will wish 
to Hide the Rows:

Paste this into L1..L12

@CELLPOINTER("ThreeDaddress")
@FIELD(L1,2,"$")
@FIELD(L1,3,"$")
@VALUE(@FIELD(L1,4,"$"))

{ReCalc L1..L4}
{Let L5, L4}
{ReCalc L9}
+"{IF
"&L2&L3&@STRING(L5,0)&"=""""}{RowC
olShow 
"&L2&L3&@STRING(L5,0)&", 0, 1, 0}"
{Let L5, L5+1}
{IF L5>N2}
{BRANCH L8}

Into M2:
LastRow:

Into N2, type the number of the last row to be checked.

Save the file.
Put the cursor into the Column to be checked and the first Row 
to be checked.

Do: Alt-F2. Type: A:L6
but if you chose a different Sheet for the macro, then use the 
ID of that Sheet instead, e.g: D:L6.
[Enter]

If you Name L6, then calling the macro is easier.

Easier yet, and worth it if you use the macro often:
There is a Help Page: To attach a macro to a keystroke 
which you find through Help!Topics|Index:
macros, attaching to keystrokes, [Display].
Be sure not to choose a keystroke already used by QP.
If your keystroke does not call up the macro, then either you 
have chosen one of the reserved keystrokes or you made a mistake 
in the keystroke setup.
-- 
Good wishes!
Roy Lewis
C_Tech volunteer
(UK)

Post Reply
about | contact