• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

VBA snippet required

Mr.Karr

Member
Hello,

I have column A where used range is. According to that, can someone please provide a code snippet to fill up column B with "Completed".

Please see attached file.

Thanks,
Kar
 

Attachments

  • sample file.xlsm
    9.8 KB · Views: 7
Thank you @Debaser. It works like a breeze.
In case I've next set of data in column A and would like to enter another region the same way, how about we do it ?

Please see attached file.
 

Attachments

  • sample file.xlsm
    9.8 KB · Views: 6
For example:
Code:
range("B2:B" & cells(rows.Count, "A").end(xlup).row).SpecialCells(xlCellTypeBlanks).Value2 = "Another country"
 
@Debaser, a quick question.
I am trying above provided snippet code with GetData query and seeing error mentioned below;
Run-time error '1004';
No cells were fouind

Can you please help as this is spoiling everything which is been built.
 
Hi !​
In case I've next set of data in column A and would like to enter another region the same way, how about we do it ?
Just using Excel basics, an easy formula !
No error without any blank cell to fill …​
Code:
Sub Demo()
       Const F = "IF(#2>"""",#2,""#C"")"
    With Cells(1).CurrentRegion.Columns(2)
        .Value = Evaluate(Replace$(Replace$(F, "#2", .Address), "#C", "Japan"))
    End With
End Sub
Do you like it ? So thanks to click on bottom right Like !
 
Back
Top