ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Show UserForm if cell is emprty. (https://www.excelbanter.com/excel-discussion-misc-queries/216296-show-userform-if-cell-emprty.html)

Tdp

Show UserForm if cell is emprty.
 
How can I get a UserForm to pop up, when a page is opened, only if a cell is
empty?
--
Tdp

Bob Phillips[_3_]

Show UserForm if cell is emprty.
 
Private Sub Worksheet_Activate()
If Range("A1").Value = "" Then UserForm1.Show
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
How can I get a UserForm to pop up, when a page is opened, only if a cell
is
empty?
--
Tdp




Tdp

Show UserForm if cell is emprty.
 
Thanks for that.
I'v tried modifying your code so that when the workbook opens to sheet1
everytime. Userform1 to show if Range("a1") in Sheet7 is empty, but with no
luck!!!
I'm using the following:

Private Sub Workbook_Open()
If Sheet7.Range("B6").Value = "" Then UserForm3.Show
End Sub

I'v placed this code in "ThisWorkbook"

--
Tdp


"Bob Phillips" wrote:

Private Sub Worksheet_Activate()
If Range("A1").Value = "" Then UserForm1.Show
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
How can I get a UserForm to pop up, when a page is opened, only if a cell
is
empty?
--
Tdp





Bob Phillips[_3_]

Show UserForm if cell is emprty.
 
You have said Range("a1") but coded Range("B6")

--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
Thanks for that.
I'v tried modifying your code so that when the workbook opens to sheet1
everytime. Userform1 to show if Range("a1") in Sheet7 is empty, but with
no
luck!!!
I'm using the following:

Private Sub Workbook_Open()
If Sheet7.Range("B6").Value = "" Then UserForm3.Show
End Sub

I'v placed this code in "ThisWorkbook"

--
Tdp


"Bob Phillips" wrote:

Private Sub Worksheet_Activate()
If Range("A1").Value = "" Then UserForm1.Show
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
How can I get a UserForm to pop up, when a page is opened, only if a
cell
is
empty?
--
Tdp







Tdp

Show UserForm if cell is emprty.
 
Sorry it is "A1". I was multi-tasking at the time!!
--
Tdp


"Bob Phillips" wrote:

You have said Range("a1") but coded Range("B6")

--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
Thanks for that.
I'v tried modifying your code so that when the workbook opens to sheet1
everytime. Userform1 to show if Range("a1") in Sheet7 is empty, but with
no
luck!!!
I'm using the following:

Private Sub Workbook_Open()
If Sheet7.Range("B6").Value = "" Then UserForm3.Show
End Sub

I'v placed this code in "ThisWorkbook"

--
Tdp


"Bob Phillips" wrote:

Private Sub Worksheet_Activate()
If Range("A1").Value = "" Then UserForm1.Show
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
How can I get a UserForm to pop up, when a page is opened, only if a
cell
is
empty?
--
Tdp







Bob Phillips[_3_]

Show UserForm if cell is emprty.
 
Does it now work with A1?

--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
Sorry it is "A1". I was multi-tasking at the time!!
--
Tdp


"Bob Phillips" wrote:

You have said Range("a1") but coded Range("B6")

--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
Thanks for that.
I'v tried modifying your code so that when the workbook opens to sheet1
everytime. Userform1 to show if Range("a1") in Sheet7 is empty, but
with
no
luck!!!
I'm using the following:

Private Sub Workbook_Open()
If Sheet7.Range("B6").Value = "" Then UserForm3.Show
End Sub

I'v placed this code in "ThisWorkbook"

--
Tdp


"Bob Phillips" wrote:

Private Sub Worksheet_Activate()
If Range("A1").Value = "" Then UserForm1.Show
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
How can I get a UserForm to pop up, when a page is opened, only if a
cell
is
empty?
--
Tdp









Tdp

Show UserForm if cell is emprty.
 
No, I'm afraid not.
--
Tdp


"Bob Phillips" wrote:

Does it now work with A1?

--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
Sorry it is "A1". I was multi-tasking at the time!!
--
Tdp


"Bob Phillips" wrote:

You have said Range("a1") but coded Range("B6")

--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
Thanks for that.
I'v tried modifying your code so that when the workbook opens to sheet1
everytime. Userform1 to show if Range("a1") in Sheet7 is empty, but
with
no
luck!!!
I'm using the following:

Private Sub Workbook_Open()
If Sheet7.Range("B6").Value = "" Then UserForm3.Show
End Sub

I'v placed this code in "ThisWorkbook"

--
Tdp


"Bob Phillips" wrote:

Private Sub Worksheet_Activate()
If Range("A1").Value = "" Then UserForm1.Show
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"Tdp" wrote in message
...
How can I get a UserForm to pop up, when a page is opened, only if a
cell
is
empty?
--
Tdp











All times are GMT +1. The time now is 02:21 PM.

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