Condicionar a una celda vacia

Osasa54

New Member
Joined
Sep 10, 2002
Messages
31
Hola estoy realizando en VBA un If, pero a la hora de poner la condición no se como describir una celda vacia

Ej if range("n12") = then

goto dos

end if


He probado con null, con 0, con "", pero no consigo que me reconozca el valor vacio de la celda
Seguro que es una tonteria que se me está escapando. Alguien lo sabe????
:D
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
si utilizas la instruccion If como tu la tienes
funciona para la hoja activa nada mas y posiblemente
tu hoja activa tiene valor y el if nunca dará verdadero,
pero si especifica la hoja ya sea:
if application.sheets(1).range("N12")="" then O
if hoja1.range("N12")="" tiene que funcionar
espero te sirva un saludo
[/code]
 
Upvote 0

Forum statistics

Threads
1,215,758
Messages
6,126,702
Members
449,331
Latest member
smckenzie2016

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top