can someone tell me what would be the equivalent vb.net code for the below excel macro code:
Selection.Find(What:="FALSE", After:=ActiveCell, LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False).Activate
I have changed the code to
ObjWs1.Application.Selection.Find(What:="FALSE", After:=ObjWs1.Application.ActiveCell, LookIn:=Microsoft.Office.Interop.Excel.XlFindLookIn.xlFormulas, _
LookAt:=Microsoft.Office.Interop.Excel.XlLookAt.xlPart, SearchOrder:=Microsoft.Office.Interop.Excel.XlSearchOrder.xlByRows, SearchDirection:=Microsoft.Office.Interop.Excel.XlSearchDirection.xlNext, _
MatchCase:=False, SearchFormat:=False).Activate()
when I run this code I am getting an error and the description is:
"Object variable or With block variable not set"
Thanks.
Selection.Find(What:="FALSE", After:=ActiveCell, LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False).Activate
I have changed the code to
ObjWs1.Application.Selection.Find(What:="FALSE", After:=ObjWs1.Application.ActiveCell, LookIn:=Microsoft.Office.Interop.Excel.XlFindLookIn.xlFormulas, _
LookAt:=Microsoft.Office.Interop.Excel.XlLookAt.xlPart, SearchOrder:=Microsoft.Office.Interop.Excel.XlSearchOrder.xlByRows, SearchDirection:=Microsoft.Office.Interop.Excel.XlSearchDirection.xlNext, _
MatchCase:=False, SearchFormat:=False).Activate()
when I run this code I am getting an error and the description is:
"Object variable or With block variable not set"
Thanks.