#1
|
|||
|
|||
Concatenate and Do While Loop VBA
I have a Workbooks("Serial Number").Sheet1 where Column B contains data such as 0001, 0002 , 0003 , 0004 upto 9999 row wise and other Workbooks("Data").Sheet1 have data where ColA has such values
205-371- 205-372- 205-373- 205-374- till used range row wise and i am looking to merge the data like below example on the Workbooks("Data").Sheet1 ColA. 205-371-0001 205-371-0002 205-371-0003 205-371-0004 after that wants to add the loop in the formula section in below code. HTML Code:
Sub Looping() Dim xFd As FileDialog Dim xFdItem As Variant Dim xFileName As String Application.ScreenUpdating = False Application.DisplayAlerts = False Set xFd = Application.FileDialog(msoFileDialogFolderPicker) If xFd.Show = -1 Then xFdItem = xFd.SelectedItems(1) & Application.PathSeparator xFileName = Dir(xFdItem & "*.csv*") Wants to add here a concatenate formula with Do While Loop for all sheets a folder have. End If Dim wb As Workbook For Each wb In Workbooks wb.Close SaveChanges:=True Next wb Application.DisplayAlerts = True Application.ScreenUpdating = True End Sub |
#2
|
||||
|
||||
What you described and what the code shows are very different.
You need to post example workbooks if you want help on this.
__________________
Andrew Lockton Chrysalis Design, Melbourne Australia |
Tags |
vba code |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Concatenate - function help | ganesang | Excel | 29 | 12-27-2018 05:31 AM |
Concatenate Macro VBA | rsrasc | Excel Programming | 4 | 09-21-2018 12:42 PM |
Concatenate | b16 | Excel | 1 | 01-09-2017 04:51 PM |
Concatenate with @ symbol | anickles | Excel | 2 | 02-06-2015 09:39 AM |
If, move and concatenate in VBA | devcon | Excel Programming | 0 | 07-04-2011 12:44 AM |