Intermittent code issue

W

wilro85

I'm having the strangest problem. I have this code (shown below) that
works fine on my computer. However, when a co-worker runs the code, it
generates an error, highlighting the italic area. Any idea why this
would work on one machine but not on another?

Sub CommandButton2_Click()
If CheckBox2.Value = True And Range("A25").Value = "" Or
CheckBox5.Value = True And Range("a43").Value = "" Or _
Worksheets("page1").CheckBox2.Value = True And
Worksheets("page1").Range("a28").Value = "" Or _
Worksheets("page1").CheckBox3.Value = True And
Worksheets("page1").Range("a34").Value = "" Then
MsgBox ("You have indicated a PO number, ACE number, Project Module
Number, or Customer Estimate" & vbCrLf & _
"exists but did not specify a value. Please correct this mistake.")
Else
_*-MyCellValue_=-*_ Sheets("Page1").Range("a19").Value
LResponse = MsgBox("Do you wish to submit the Engineering Request Form
for " & MyCellValue & "?", vbYesNo, "Day Wireless Systems
Engineering")
If LResponse = vbYes Then
Call WBunlock
Sheets("ERFSummary").Visible = True
Sheets("ERFSummary").Range("B39").Value = Range("A43").Value
ActiveWorkbook.SendMail "(e-mail address removed)", _
"Engineering Request Form " & MyCellValue,
True
MsgBox "The Form has been Sent", vbOKOnly, "Day Wireless
Systems Engineering"
If CheckBox3.Value = True Then
ActiveWorkbook.FollowHyperlink
Address:="http://sharepoint.dayintranet.com/engineering/Project Forms/Coverage Map Request Form.XLT",
_
NewWindow:=True
End If
Else
MsgBox "The Form was Not Sent", vbOKOnly, "Day Wireless Systems
Engineering"
End If
End If
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top