E
Eric
Does anyone have any suggestions on how I can insert the Counter into the web
link? and change the column location for pasting selection?
Following code is generated by recording Macro, please see Coding section
If the counter is 1, then paste into Columns("A:A").Select under Summary
worksheet.
If the counter is 2, then paste into Columns("B:B").Select under Summary
worksheet.
....
If the counter is 10, then paste into Columns("J:J").Select under Summary
worksheet.
Does anyone have any suggestions?
Thanks in advance forany suggestions
Eric
===============
Coding
===============
For Counter = 1 to 10
'Your code
Next Counter
With ActiveSheet.QueryTables.Add(Connection:= _
"URL;http://www.uwants.com/forumdisplay.php?fid=845&page=1",
Destination:= _
Range("A1"))
.Name = "forumdisplay.php?fid=845&page=1"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = True
.BackgroundQuery = True
.RefreshStyle = xlInsertEntireRows
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.WebSelectionType = xlEntirePage
.WebFormatting = xlWebFormattingNone
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With
ActiveWindow.LargeScroll ToRight:=2
Columns("F:F").Select
Selection.Copy
Sheets("Sheet2").Select
Columns("A:A").Select
ActiveSheet.Paste
End Sub
link? and change the column location for pasting selection?
Following code is generated by recording Macro, please see Coding section
If the counter is 1, then paste into Columns("A:A").Select under Summary
worksheet.
If the counter is 2, then paste into Columns("B:B").Select under Summary
worksheet.
....
If the counter is 10, then paste into Columns("J:J").Select under Summary
worksheet.
Does anyone have any suggestions?
Thanks in advance forany suggestions
Eric
===============
Coding
===============
For Counter = 1 to 10
'Your code
Next Counter
With ActiveSheet.QueryTables.Add(Connection:= _
"URL;http://www.uwants.com/forumdisplay.php?fid=845&page=1",
Destination:= _
Range("A1"))
.Name = "forumdisplay.php?fid=845&page=1"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = True
.BackgroundQuery = True
.RefreshStyle = xlInsertEntireRows
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.WebSelectionType = xlEntirePage
.WebFormatting = xlWebFormattingNone
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With
ActiveWindow.LargeScroll ToRight:=2
Columns("F:F").Select
Selection.Copy
Sheets("Sheet2").Select
Columns("A:A").Select
ActiveSheet.Paste
End Sub