Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 206
Default ISBLANK for a Range

Hi There,

ISBLANK-function works only for a a single cell -to my knowledge-.
Anyone has a UDF which can evaluate a range?

Brgds
Sige

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default ISBLANK for a Range

Hi Sige,

Try:

Application.CountA(Selection) = 0

---
Regards,
Norman



"Sige" wrote in message
oups.com...
Hi There,

ISBLANK-function works only for a a single cell -to my knowledge-.
Anyone has a UDF which can evaluate a range?

Brgds
Sige



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 206
Default ISBLANK for a Range

Hi Norman,
That simple thx!

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default ISBLANK for a Range

Hi Sige,

As you asked for a UDF, try:

Function RangeBlank(Rng As Range) As Boolean
RangeBlank = Application.CountA(Rng) = 0
End Function

---
Regards,
Norman



"Sige" wrote in message
oups.com...
Hi There,

ISBLANK-function works only for a a single cell -to my knowledge-.
Anyone has a UDF which can evaluate a range?

Brgds
Sige



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 206
Default ISBLANK for a Range

Thx Norman!



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default ISBLANK for a Range

why not just =If(counta(rng)=0,"Blank","Not Blank")

rather than encasulate it in a UDF

--
Regards,
Tom Ogilvy

"Sige" wrote in message
oups.com...
Thx Norman!



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 206
Default ISBLANK for a Range

Indeed Tom, why not ;o)

PS:
I remember there was a way to add a "sort-of-comment" in a formula...
without affecting the formula.

Something like eg.:
=If(counta(rng)=0,"Blank","Not Blank") *T("This is function returns
true or false when range is empty")
or
=If(counta(rng)=0,"Blank","Not Blank") +Text("This is function returns
true or false when range is empty")
or
.... I have no idea anymore how it was ...

  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default ISBLANK for a Range

=If(counta(rng)=0,"Blank","Not Blank") &Left("This is function returns . . .
",0)

seems to work.

--
Regards,
Tom Ogilvy


"Sige" wrote in message
oups.com...
Indeed Tom, why not ;o)

PS:
I remember there was a way to add a "sort-of-comment" in a formula...
without affecting the formula.

Something like eg.:
=If(counta(rng)=0,"Blank","Not Blank") *T("This is function returns
true or false when range is empty")
or
=If(counta(rng)=0,"Blank","Not Blank") +Text("This is function returns
true or false when range is empty")
or
... I have no idea anymore how it was ...



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
isblank [email protected] Excel Worksheet Functions 4 December 23rd 09 05:38 AM
Isblank Lishen New Users to Excel 2 April 17th 09 12:25 PM
IF AND ISBLANK Louise Excel Worksheet Functions 1 February 7th 08 08:03 PM
isblank range JB2010 Excel Discussion (Misc queries) 5 March 22nd 07 03:42 PM
Can you test for a range (Q16:19) any cell is ISBLANK CRayF Excel Programming 2 September 25th 05 06:18 AM


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

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"