Below is my code
Sub Append() 'Append data from other files Path = "E:\NPM PahseIII\" Filename = Dir(Path & "*.xlsx") If InStr(Filename, ".") > 0 Then Filenamenoext = Left(Filename, InStr(Filename, ".") - 1) End If MsgBox Filenamenoext Range("A3").Select Do While Filename <> "" ActiveCell.Value = Filenamenoext Loop End Sub My problem is that as I've selected Range("A3").Select is hard coded, i want this selection to be done dynamically in loop such that when the first iteration of the loop start it should select Range("A3").Select & further select next cell in the next iteration. How can i achieve this? Edited See image below 
Range.End(xlUp).Offset(1)- basically find the last populated cell in the column and offset 1 row. Many examples on SO of how to do this.