ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   if range=nothing then (https://www.excelbanter.com/excel-programming/351586-if-range%3Dnothing-then.html)

filo666

if range=nothing then
 
Hi, I don't know how to use an if structure with arange:

rngEndCell is a range

If rngEndCell = Nothing Then
ssss = Cells(47, columna).Address(False, False)
Set rngEndCell = Range(ssss)
End If

the error 91 appears

how to accoplish this???

RB Smissaert

if range=nothing then
 
You will need:
If rngEndCell Is Nothing Then
as rngEndCell is an object, a range object.

RBS

"filo666" wrote in message
...
Hi, I don't know how to use an if structure with arange:

rngEndCell is a range

If rngEndCell = Nothing Then
ssss = Cells(47, columna).Address(False, False)
Set rngEndCell = Range(ssss)
End If

the error 91 appears

how to accoplish this???



filo666

if range=nothing then
 
Thanks silly me¡¡¡¡

"RB Smissaert" wrote:

You will need:
If rngEndCell Is Nothing Then
as rngEndCell is an object, a range object.

RBS

"filo666" wrote in message
...
Hi, I don't know how to use an if structure with arange:

rngEndCell is a range

If rngEndCell = Nothing Then
ssss = Cells(47, columna).Address(False, False)
Set rngEndCell = Range(ssss)
End If

the error 91 appears

how to accoplish this???





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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com