hi i have sheet with 3 column, i want to find first "0" in column B and copy C1 value to A column that side of "0"
i need vba code for this sample
tanks
Capture.JPG
hi i have sheet with 3 column, i want to find first "0" in column B and copy C1 value to A column that side of "0"
i need vba code for this sample
tanks
Capture.JPG
For the future, please post workbook samples (Go Advanced /Manage Attachments) rather than screenshotsSub Test() Set c = Columns(2).Find(0, after:=Cells(Rows.Count, 2), lookat:=xlWhole, searchdirection:=xlNext) If Not c Is Nothing Then c.Offset(, -1) = Range("C1") Else MsgBox "0 not found" End If End Sub
MVP (Excel 2008-2010)
Post a workbook with sample data and layout if you want a quicker solution.
To help indent your macros try Smart Indent
Please remember to mark threads 'Solved'
cross post:
https://stackoverflow.com/q/47175701