Locked as code not wrapped
Hi,
My requirement is to copy the content of a file from txt file and paste it in a workbook. from google i got this code
Dim DestBook As Workbook, SourceBook As Workbook
Dim DestCell As Range
Dim RetVal As Boolean
Application.ScreenUpdating = False
Set DestBook = ActiveWorkbook
Set DestCell = ActiveCell
RetVal = Application.Dialogs(xlDialogOpen).Show("*.*")
If RetVal = False Then Exit Sub
Set SourceBook = ActiveWorkbook
Range(Range("A1"), Range("A1").SpecialCells(xlLastCell)).Copy
DestBook.Activate
DestCell.PasteSpecial Paste:=xlValues
SourceBook.Close False
When i run this, it opens the file selection dialogue box and then it asks for selecting delimiter options. i want to skip the delimiter selection. any way to do it. my macro should be simply copy paste from the txt file
any other code is welcome.
Ashish
Bookmarks