ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Command Button Problems Still (https://www.excelbanter.com/excel-programming/332083-command-button-problems-still.html)

Mikeice[_23_]

Command Button Problems Still
 

HI ALL

Now if I put in the a value and then delete the value the Command
Button 3 goes to disable but the Command Button 1 does not. I can't
understand why.

Please help, thx in advance




Private Sub Worksheet_SelectionChange(ByVal Target As Range)


If Sheets("Quality Accessing Template").Range("B6").Value = "0" And
Sheets("Quality Accessing Template").Range("B6").Value <= "9999" Then
Sheets("Quality Accessing Template").CommandButton3.Enabled = True
Sheets("Quality Accessing Template").CommandButton1.Enabled = True


Else


Sheets("Quality Accessing Template").CommandButton3.Enabled = False
Sheets("Quality Accessing Template").CommandButton3.Enabled = False

End If

End Sub


--
Mikeice
------------------------------------------------------------------------
Mikeice's Profile: http://www.excelforum.com/member.php...o&userid=22467
View this thread: http://www.excelforum.com/showthread...hreadid=380009


mangesh_yadav[_335_]

Command Button Problems Still
 

First thing, remove the quotes around 0 and 999
Second thing, you are not disabling the commandbutton1. Check your else
code, both are 3.

Mangesh


--
mangesh_yadav
------------------------------------------------------------------------
mangesh_yadav's Profile: http://www.excelforum.com/member.php...o&userid=10470
View this thread: http://www.excelforum.com/showthread...hreadid=380009


Don Guillett[_4_]

Command Button Problems Still
 
and use with/end with


--
Don Guillett
SalesAid Software

"mangesh_yadav"
wrote in message
news:mangesh_yadav.1qrjmn_1118999182.5718@excelfor um-nospam.com...

First thing, remove the quotes around 0 and 999
Second thing, you are not disabling the commandbutton1. Check your else
code, both are 3.

Mangesh


--
mangesh_yadav
------------------------------------------------------------------------
mangesh_yadav's Profile:

http://www.excelforum.com/member.php...o&userid=10470
View this thread: http://www.excelforum.com/showthread...hreadid=380009





All times are GMT +1. The time now is 05:29 PM.

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