Web Query

Joneye

Well-known Member
Joined
May 28, 2010
Messages
777
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
  2. MacOS
I have a excel sheet that draws in google shares information, this is pulled in every 6 minutes.

The cell changes as per the price of the share, is there any possible way to have the previous cells data extracted to another cell before the new data arrives?

Is this a VBA function or is their a formula?
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
Hi Jon
I believe this is a VBA solution.
IS it your macro that pulls data from the Web ??
If so, before it does the pull place the lines ( change to suit), in the macro
Code:
Range("A1").Copy Destination:=Range("A2")
 
Upvote 0
I use the Web Query Feature under the data tab to draw in the information.

It comes into a tab and in a master sheet I draw in the cell im interested in.

Does this help?
 
Upvote 0
Are you using code...if so, maybe you should post it.
Did you look at Andrews link
 
Upvote 0
No code, its a feature in excel 2003, click on the data tab, scrol down to import external data then select New Web Query

No code unless its hidden from me.
 
Upvote 0
Jon
Yeah, I know how Web query works. I thought you may have created a macro to run it and then we could simply add the copy / paste

I use this snippet to run my Web quesry and it would be simple to add the line to copy and paste at the beginning.
Code:
Sub NRL()
Range("D2:M19").Clear 'you could add your copy and paste here
Range("D2").Select
Application.DisplayAlerts = False
    With Selection.QueryTable
        .Connection = "URL;http://www.thescore.com.au/nrl/ladder.html"
        .WebSelectionType = xlSpecifiedTables
        .WebFormatting = xlWebFormattingAll
        .WebTables = "1"
        .WebDisableRedirections = True
        .Refresh BackgroundQuery:=False
    End With
    Columns("E:L").ColumnWidth = 4.71
Range("I2:M2").ClearContents
ActiveWorkbook.Save
End Sub
hope this gives you some ideas.
 
Upvote 0

Forum statistics

Threads
1,213,538
Messages
6,114,217
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top