Compile A Web Page To Which There Are Many Many Queries?

Feb 10, 2010

how would you compile a web page to which there are many many querys?
i.e a website that has links to results

View 9 Replies


ADVERTISEMENT

Page Break Preview It Shows The Page Numbers In The Centre Of The Page

Jun 9, 2009

When I view a sheet under Page Break Preview, it shows the Page numbers in the centre of the Page. While I am aware that it would not print the page number I was wondering if there is an option to remove/hide the page numbers.

View 3 Replies View Related

Combine The IF And OR Queries

Jan 8, 2009

Trying to write an IF query looking for multiple returns that would equal the same result.

I have a series of number where the last digit would result in the same return if the digit were 1 or 6, 2 or 7, 3 or 8, etc.

1 or 6 = 1
2 or 7 = 2

I have been trying unsuccessfully to combine the IF and OR queries

View 12 Replies View Related

Using Lookups & IF Queries Together?

Dec 28, 2012

I'm currently working on a side project for work that I believe will save many man hours as at the moment we're using paper and calculators!!! I'm scheduling buys. I've worked out formulas and formats to show how much we should buy and how they should be split (for example for UK purchases we buy x amount and split it 10% 90%). However, the dates of delivery are different. See below:

PORT L'poolPORT HKPORT Portsmouth
1.113-Aug-1206-Aug-1230-Jul-12
1.210-Sep-1203-Sep-1227-Aug-12
2.103-Sep-1227-Aug-1220-Aug-12
2.201-Oct-1224-Sep-1217-Sep-12
3.124-Sep-1217-Sep-1210-Sep-12
3.222-Oct-1215-Oct-1208-Oct-12

Campaign 1 first buy (1.1) I know that my product is sailing from port HK. Therefore I want it that in the 'delivery date' cell, it returns 6/aug/12 (that's the first lot of 10%, and underneath it returns 3/sep/12) which the remaining 90%...2.2).

However, both the campaign number AND port options are variable (using a data validation drop down list). In effect meaning if I choose campaign 2 instead of campaign one, it'll return the dates 27/aug and 24 sep....if I then change the port to Portsmouth, the dates will be 20 aug and 17 sep.

I've attached a quick view of the schedule I've created. The yellow cells are where I want the dates to be returned.

ScheduleEX.jpg

View 4 Replies View Related

Precision Through Queries

Apr 28, 2009

I have a program that uses a query to grab data from overseas. I have an issue where some precision is apparently lost and I was curious if there was a way around this.

As an example of what is going on I have a specific piece of data I am tracking. The value is 14.9 in the SQL database and it's datatype there is a real of length 4. After grabbing this item from the query I checked the record set and the value is still 14.9. After it reaches the worksheet though it is displayed as 14.89999962. The destination cell is currently formatted as General but I have tried Text as well. Both produce the same results. As this tool is very general I would not have it formatted as a number as I don't know what I am getting back exactly.

I know computers store real/single values inprecisely but I see it everywhere else as 14.9. I would think Excel would display what I am seeing. Is there anyway around this short of formatting the cell as number with 1 decimal place?

View 4 Replies View Related

VBA Inputbox To Sql Queries

Jul 31, 2007

The report is a "template" that will be ran once a month every month and will look back at the previous month's data. What i've invisioned is writing a vb script to load on workbook open asking various questions via "inputbox()" method.

SET NOCOUNT ON
DECLARE @StartDate DateTime
DECLARE @EndDate DateTime
SET @StartDate = '20070731 10:10:51.450'
SET @EndDate = '20070731 10:11:51.450'
SET ROWCOUNT 100
SET NOCOUNT OFF
SELECT EventTagName = EventHistory.TagName, Value
FROM EventHistory
INNER JOIN AnalogSnapshot ON EventHistory.EventLogKey = AnalogSnapshot.EventLogKey
INNER JOIN SnapshotTag ON SnapshotTag.SnapshotTagKey = AnalogSnapshot.SnapshotTagKey
WHERE SnapshotTag.TagName IN ('SysSpaceMain')
AND DateTime >= @StartDate
AND DateTime

View 9 Replies View Related

Web Queries In Modules

Aug 8, 2006

I'm trying to produce a spreadsheet that pulls infomation from different web pages throughout the day. It needs to pull quite a large amount of information from different web pages hence I wanted to produce a subroutine which could be called with different variables for each web page, i.e. url, field, destination, etc.

To actually produce the query I recorded a macro and then used the code it produced. I then changed the URL to url, a string variable which holds the urls of the pages. The destion address was changed to destination, a range variable to store the destionation location, and the webTable was changed to table also a string variable to store the table number. This is shown below.

With ActiveSheet.QueryTables.Add(Connection:= _
url, Destination:= destination)
.Name = "q?s=%5EFTSE&m=L_137"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = False
.BackgroundQuery = True
.RefreshStyle = xlInsertDeleteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True.............................

View 2 Replies View Related

Parameter Queries In Vba

Mar 30, 2007

I want know how to pass a parameter through a cell for date in the following url

http://fc-web-phl1-101.phl1:8090/gp/...runReport.y=10

View 9 Replies View Related

Put In Error Handling In Case The Format Of The Page Changes Or The Internet Page Is Unavailable

May 18, 2006

I have some code that parses an html table. I want to put in error handling in case the format of the page changes or the internet page is unavailable. I am testing without an internet connection and the run time error is not being branched off to the error handler and is fatally ending the macro. This is true also if I raise an error manually.

Private Sub ParseInjuryPage()
On Error Goto ErrorHandl
Dim strPage As String
Dim webIE As SHDocVw.InternetExplorer
Dim myURL As String
Dim tableBeg As Long
Dim tableEnd As Long
Dim RowBeg As Long
Dim rowEnd As Long
Dim cellBeg As Long
Dim cellEnd As Long
Dim strBeg As Long
Dim strEnd As Long
Dim myCell As Range
Dim rowNum As Integer
With Sheets("INJ")
Set myCell = .Range("A2")
.Range("A:F").Value = vbNullString
rowNum = 2
Set webIE = New SHDocVw.InternetExplorer
myURL = "http://www.sportsline.com/nfl/injuries"
webIE.Navigate myURL
Do Until webIE.ReadyState = READYSTATE_COMPLETE
DoEvents
Loop
strPage = webIE.Document.body.innerhtml...................................

View 6 Replies View Related

Web Queries For Multiple Pages?

Dec 10, 2008

My question is about webqueries... specifically how to set up a query that will automatically fetch data on different pages (same data, but includes page 2, page 3, page 4, etc )

I've just figured out how to import a "new web query," but it seems like I won't be able to import 63 pages of it unless I do all of them by hand.

View 7 Replies View Related

How To Create Reports And Queries

Jan 19, 2013

i would like to create reports and queries in excel just like in access is this possible or do you import a layout,i have a sheet that has data on i would like to be able to pick just one row or mutiple rows and print them off could i save them to a menu to use over and over again,would i use a userform to search for these or can it be done otherways ,have seen pivot tables but seem bit complicated

View 2 Replies View Related

Multiple Web Queries In One Column

Mar 20, 2014

I'm new to macro and have tried copy from others who have posted before but it don't seem to lead to anywhere.

I'm trying to automated a column of web query (sheet1,column A), a batch of listing site with no tables. with the results in sheet2.

Looping part as well. Also, is it possible to just extract <title> from the page source.

Here's what I have so far.

PHP Code: 

Sub Macro1()
'
' Macro1 Macro
'
'
    With ActiveSheet.QueryTables.Add(Connection:= _
        "URL;" & Sheets("Sheet1").Range("A2") _
        , Destination:=Range("B2"))
 
[Code] ........

Tried changing the destination from

Destination:=Range("B2")) to Destination:=Range("Sheet2!$A$2"))

But keep getting error to change destination.

View 1 Replies View Related

External Data Queries

Apr 1, 2008

I use external data queries in excel. That's how I look up data in my access databases because I have so many access and SQL databases it's just eiser to be able to do quick queries on multiple databases at the same time in one spreadsheet. And, I can save the external data query as a tool to use in future queries. I have tons of tools and external data query is the foundation of most of them.

What bugs me is EDITING data.

If I want to do some light simple editing in an SQL database I am required to use a linked table in Access or SQL Studio Express Manager. Great programs, but I want to integrate!

Is there no way to make excel a database editor? I can retrieve data from any database or program with excel just fine, but is there a way to use excel to DIRECTLY EDIT the data in an external database with EXCEL like I can in access linked tables?

View 9 Replies View Related

List Of Web Site Queries

Apr 7, 2009

i have 306 web pages listed in sheet 1, A1:A306

how can i get a macro to open each and scrape a piece of info from each, and then store in a row in sheet 2?

View 9 Replies View Related

SQL Queries To Non-contiguous Range

Oct 3, 2009

I want data to columns A, C and E, while I have important data in columns B and D. Should I make three queries? Should I make query and save the results to temporary place and then move all the results to those columns A, C and E?

Right now the copying happens like this:

If Not rsData.EOF Then
rngTarget.CopyFromRecordset rsData
Else
MsgBox "No records returned.", vbCritical
End If

So should I do
1) One query and move everything in the right places
2) Multiple queries
3) Something else

Does this depend a lot about how many results I expect? I'd say likely about 100, maybe less than 1500, never more than 10000

View 9 Replies View Related

Making Web Queries Recursive

Jun 8, 2006

Hello folks! Here's to hoping I can eventually be a source of information rather than questions. But enough about me - on to the topic at hand.

I have a single-source web query that I'd like to expand.

Here's what I have in the IQY file:

VB: AutoLinked keywords will cause extra spaces before keywords. Extra spacing is NOT transferred when copy/pasting, but IS if the keyword uses "quotes" ...

View 9 Replies View Related

Sort Multiple Web Queries

Nov 10, 2006

In short I have a yahoo query that loop through about fifty or so stock symbols. The query data is in column A to G starting with: Date, open,high,low ,close Adj. Now I have my Destination set up like so “Destination:= Range("A65536").End(xlUp).Offset(3))” for 3 row space between is retrieval

The problem is my: xlAscending

Selection.Sort Key1:=Range("A65536"), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal

Ascending only convert the first query to Ascending the rest of the data remains Descending, how do I get all my query data to convert to Ascending using Date.

View 7 Replies View Related

Can't Move Page Breaks In Page Break Preview

Mar 26, 2006

I suddenly can't adjust my page breaks in any Excel spreadsheet while in Page Break Preview. Is there some option to turn it on and off?

View 7 Replies View Related

Print To Fit All Rows And Column On One Page And Take Up Entire Page?

Oct 16, 2013

I have a sheet that changes the number of columns based on data from other sheets. This is the only sheet in the workbook that I will print out every day. I have it set right now to fit all columns on one page, however sometimes this will result in the bottom 1/3rd of the sheet not being used. If I use fit all rows on one page, then some of the columns will get cut off. Is there a way to scale in both directions? My guess is there is not, but I thought I would ask because it would work great for me if I could.

View 4 Replies View Related

Printing One Page Grayscale And One Page Color With Code

May 21, 2009

I have a report that I use and right now I have a command button that prints the report x2. What I would like to do is to have it print one in color and one in grayscale. I could do this I think with two different buttons, but I would like to utilize just one. I tried creating a macro but it did not pick up the fact that I changed the properties to black and white.

View 2 Replies View Related

Countif Formula: Take Data From One Page And Graph It On Another Page

May 1, 2009

I am looking for a formula that will take data from one page and graph it on another page. The data I am trying to graph is arranged like so:

A B

1 q 2009.05.01
2 w 2009.05.02
3 w 2009.05.01
4 q 2009.05.01

I am looking for something that will look at column A and if the answer is "q" and then look at column B and if the answer is "2009.05.01" Excel will take that and count it in a specific cell on another page. In the case above, I want Excel to give me the answer of "2" in a designated cell.

View 3 Replies View Related

Change Start Page Of Multi Page UserForm

Jul 23, 2006

Is it possible to Change Start Page Of Multi Page UserForm Based on 8 CommandButtons. on a WorkSheet, for example.

CommandButton1
UserForm1.MultiPage1.Value = 0
CommandButton2
UserForm1.MultiPage1.Value = 1
CommandButton3
UserForm1.MultiPage1.Value = 2
CommandButton4
UserForm1.MultiPage1.Value = 3

Could I use 1 multipage UserForm Instead of 8 UserFoms. Is it better to use 1 multipage UserForm with 8 pages or 8 UserForms. I dont know if this make sense or not?

View 2 Replies View Related

Transfer Specific Data On Each Page To A Different Colum On That Same Page

Mar 15, 2007

I have a workbook that has 9 different tabs in it. Once all the information has been completed throughout the workbook, is there a code that could transfer specific data on each page to a different colum on that same page? I need to do this for 9 pages at one time. The information is listed differently on each page. I need to transfer data from the current data column to the previous data column once the entire workbook has been filed out.

View 2 Replies View Related

Remove Page Numbers In Page Break Preview

May 18, 2007

how to get rid of the page numbers that appear when using page break preview mode. The page numbers appear in large grey font in the middle of each page and sometimes makes it difficult to read cells. Can I use this view with all the same functionality without that one feature?

View 3 Replies View Related

Macro To Print Page Based On Active Page

Jun 29, 2007

I need a macro that will print a hidden page that is linked to the page I have active.

It needs to be able to find the correct hidden page that corresponds to the active page because there are multilple pairs of the hidden/visible pages. The name of the hidden page is the same as the visible one with "printout" added to the end. When created, the sheet code names are sheetn and sheetm; n and m being consecutive numbers.

View 3 Replies View Related

Run SQL Queries In Excel Against Database Using Macro?

Jan 29, 2014

I have sql queries in spreadsheet column and which needs to run against Db2 database daily and then update the result back to spreadsheet. This is tedious process and could there be a way to create a a macro using VB which performs the following?

1. connect to db2 database

2. take the sql query one at a time from every row and then run against database

3. Obtain the result and then update it back to last column of the spreadsheet.

View 3 Replies View Related

Automate Multiple Web Queries In One Worksheet

Jul 13, 2008

I can set up one query to take the parameters from say cell E1 and F1 and post the results of the query in cell A1.
The next query I want to take parameters from say cell E20 and F20 and post results in cell A20.
I need to run this several hundred times and am limited by the webite URL to 2 parameters.

I can't work out how to automaticaly change the URL via a macro so it adapts it with the changing parameters in my worksheet.

View 12 Replies View Related

SQL Queries And Methods - Accessing Different Database

Sep 4, 2013

Below is an example of how I prefer to work with a database. Results are fast; even across the network and I understand the syntax perfectly.

Code:
Sub DBPreferredWay()
folder = ThisWorkbook.Path & "mydatabase.mdb"
Set db = OpenDatabase(folder)
strSQL = "SELECT * FROM transactions WHERE [SimilarItems] = " & myFocus
Set tR = db.OpenRecordset(strSQL)

[Code] ........

I'm trying to access a different database; a database being hosted on my SQL server. Because of security and what not; it looks like I'm needing to use adodb but I can't stand it and the slowness (minutes to receive queries. IS there a way for me to access my sql server database similarly to how I'm accessing MDB tables across the network? Below is what I've been trying with the adodb

Code:
Sub SqltoACCPAC()
Set conn = CreateObject("adodb.connection")
Set rs = CreateObject("adodb.recordset")
phrase1 = "DRIVER=SQL Server;DATABASE=" & "VNODAT;SERVER=192.168.0.91,1433": conn.Open phrase1, "SA", "password"
strSQL = "SELECT * FROM ICITEM WHERE [SEGMENT1] >= 101 AND [SEGMENT1]

View 8 Replies View Related

Option Button And Check Box Queries

Mar 9, 2007

OPTION BUTTON

Using the Forms toolbar control, NOT ActiveX, in Excel 2002 (XP Home) to make on option button, how do I obtain more than just one option? I can draw the outline of the button and I can rename the option but I don't know how to get more than one. I'm totally green to VBA/macros/code/etc. so please keep it SUPER SIMPLE.

I'm hoping that by selecting one of 4 options, IF formulas elsewhere in my workbook (spread over multiple sheets) can be fine tuned.

For Instance: if option 1 is chosen (on sheet 1), =sheet2!(randbetween(3,24)). if option 2 is chosen, =sheet2!(randbetween(3,30)), etc.

I'll then record a macro that will take it to a Value using CopyPaste Special. Unless there is slick way of stopping the cells from rerandomizing when the sheet is recalculated.

CHECK BOX

I hope to use check boxes, to help me CONCATENATE stuff elsewhere in my spreadsheet.

For Instance: if checkbox 1 is checked (on sheet 1), =sheet2!(conc($D$11&"
whatever is associated with the check box). if check box 2 is checked, =sheet2!(conc($D$11&" whatever is associated with the check box), etc.

View 9 Replies View Related

Prioritize Queries And Worksheet Calculations

Jul 24, 2009

I have a general question about the best way to perform multiple operations from excel and finally bring it together in one worksheet. I have currently a big worksheet (own application) which queries data from the database and then performs some calculations etc. The download takes some time and cannot be changed. Ideally I would like to separate the data download from the application and have two worksheets running at the same time. Worksheet Databaseinteraction.xls would do the queries (for example every 10 minutes), worksheet calculations.xls would do the rest.

When I start both sheets they should check that the other one is open (active). The user will interact only with the sheet calculations and do some things with it. To get the data into calculations.xls I would use an ADO call (this I have done multiple times). Databaseinteraction.xls would have to know when to start getting data from the database (for example using an ini file) and continuously query the database every 5 / 10 minutes (ontime). Calculations.xls would query the Databaseinteraction.xls also every 5 / 10 minutes. Both sheets should not freeze each other. If calculations.xls queries Databaseinteraction.xls no download from the database should be started until the first query has finished.

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved