C
CBrausa
I have been thinking as to why 6 of the 44 cells won't accept th
formula to be a mandatory fill, It's because there is a calculatio
formula in them.
This is the formula I have used. Is there some way to make it includ
these 6 cells?
Option Explicit
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim myCell As Range
Dim myRange As Range
Set myRange = Nothing
On Error Resume Next
Set myRange = Me.Range("MustFill")
On Error GoTo 0
If myRange Is Nothing Then
MsgBox "Please contact Brian Baker at 785 263 3350 ext 312 to fix th
MustFill Range"
Exit Sub
End If
For Each myCell In myRange.Cells
If myCell.Address = myCell.MergeArea.Cells(1).Address Then
If myCell.Value = "" Then
Application.EnableEvents = False
myCell.Select
Application.EnableEvents = True
Exit For
End If
End If
Next myCell
End Sub
MACRO USED FOR THE 44 SELECTED CELLS
Option Explicit
Sub testme()
With Worksheets("Product Quote"
'.Range("T4,E5,M5,T7,E8,M8,d14,M14,D16,M16,D18,M18,m19,M20,m21,U21,N23,b25,K29,B30,L31,B33,I33,B35,B39,B43,B45,F47,K47,P47,S47,V47,Y47,B49,I52,I53,I54,I55,I56,I58,Q50,S55,S56,S57").Nam
_
= "'" & .Name & "'!MustFill"
End With
End Sub
Cells I52,I53,I54,I55,I56,I58 are the ones with the formulas.
Thanks
formula to be a mandatory fill, It's because there is a calculatio
formula in them.
This is the formula I have used. Is there some way to make it includ
these 6 cells?
Option Explicit
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim myCell As Range
Dim myRange As Range
Set myRange = Nothing
On Error Resume Next
Set myRange = Me.Range("MustFill")
On Error GoTo 0
If myRange Is Nothing Then
MsgBox "Please contact Brian Baker at 785 263 3350 ext 312 to fix th
MustFill Range"
Exit Sub
End If
For Each myCell In myRange.Cells
If myCell.Address = myCell.MergeArea.Cells(1).Address Then
If myCell.Value = "" Then
Application.EnableEvents = False
myCell.Select
Application.EnableEvents = True
Exit For
End If
End If
Next myCell
End Sub
MACRO USED FOR THE 44 SELECTED CELLS
Option Explicit
Sub testme()
With Worksheets("Product Quote"
'.Range("T4,E5,M5,T7,E8,M8,d14,M14,D16,M16,D18,M18,m19,M20,m21,U21,N23,b25,K29,B30,L31,B33,I33,B35,B39,B43,B45,F47,K47,P47,S47,V47,Y47,B49,I52,I53,I54,I55,I56,I58,Q50,S55,S56,S57").Nam
_
= "'" & .Name & "'!MustFill"
End With
End Sub
Cells I52,I53,I54,I55,I56,I58 are the ones with the formulas.
Thanks