ca1358
asked on
Please help with the syntax.
Excel VBA
I need to join these two statments together.
Sheet22.Range("SRP") = Sheet38.Range("e6") / 100 and
Sheet22.Range("AA28:AA57") = Sheet38.Range("e6") / 100
Please help with the syntax.
Here is the whole piece of code.
////////////////////////// ////////// ////////// /////////
If Range("W28") = "Govt" Then
Sheet22.Range("SRP") = Sheet38.Range("e6") / 100
Sheet22.Range("AA28:AA57") = Sheet38.Range("e6") / 100
Else
Sheet22.Range("SRP") = Sheet38.Range("d6") / 100
Sheet22.Range("AA28:AA57") = Sheet38.Range("d6") / 100
End If
I need to join these two statments together.
Sheet22.Range("SRP") = Sheet38.Range("e6") / 100 and
Sheet22.Range("AA28:AA57")
Please help with the syntax.
Here is the whole piece of code.
//////////////////////////
If Range("W28") = "Govt" Then
Sheet22.Range("SRP") = Sheet38.Range("e6") / 100
Sheet22.Range("AA28:AA57")
Else
Sheet22.Range("SRP") = Sheet38.Range("d6") / 100
Sheet22.Range("AA28:AA57")
End If
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I have the answer. I split the procedure and move one of them to another event.
Thanks for the help!
Thanks for the help!
ASKER
One after the Userform.Combo1 (AfterUpdate) and works fine but
I using it after a Combo1 (Change event) on the spreadsheet and I am getting error
Runtime 1004
Application-define or object deine error.
Any suggestions?
Thank you for you help!