type mismatch error

S

sam

Hi All, I am trying to update two sheets in different workbooks with the same
user input accepted through userform and I am getting a type mismatch error.
Here is where I am getting the error:

If Male.Value = True Then
ws.Cells(iRow, 2).Value = "Yes" And wst.Cells(2, 2).Value = "Yes"
End If

ws and wst are two seperate sheets in two seperate workbooks.

Thanks in Advance
 
J

john

hi Sam,
try it this way:

If Male.Value = True Then
ws.Cells(iRow, 2).Value = "Yes"
wst.Cells(2, 2).Value = "Yes"
End If
 
S

sam

that works great! Thank you

john said:
hi Sam,
try it this way:

If Male.Value = True Then
ws.Cells(iRow, 2).Value = "Yes"
wst.Cells(2, 2).Value = "Yes"
End If
 

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