Excel Help

Discussion in 'Strategy Building' started by JDConner, Feb 8, 2006.

  1. JDConner

    JDConner

    I'm importing data to Excel and I'm trying to save the high and low price for the day. Any help would be appreciated.

    JD Conner
     
  2. ktm

    ktm

    MAX and MIN.
     
  3. JDConner

    JDConner

    I tried that but I,m getting data from just one cell.
     
  4. place all data in column A then in cell B1 type the following formula:

    =Max(A:A)

    within B2 type in the following formula

    =Min(A:A)
     
  5. JDConner

    JDConner

    I tried the =max(a:a) it didn't work.
    I'm importing the last trade price of a stock in one cell, I like to know the high and low price of that one cell.
     
  6. ktm

    ktm

    ?

    I think we're going to need a bit more info.
     
  7. omniscient

    omniscient Guest

    what feed are you importing from?
     
  8. You'll need to use VBA to compare the cell value to another cell everytime the worksheet updates. I assume you're using a DDE feed or something to get the data in? At any rate, it's not hard to do, the basic logic is this.

    Assuming the value is in A1 and you want the high in B1

    if A1 > B1 then

    B1 = A1

    end if

    The only thing to remember is that if B1 is blank, it will be treated as 0.

    Hope that helps,

    - The New Guy
     
  9. JDConner

    JDConner

    It's the high price and low price for the day, just like you see on a quote board.

    Last Trade Pr High Low
    45.58 45.60 45.40
     
  10. omniscient

    omniscient Guest

    i ask which feed because using IB i can get H/L with the following syntax:

    ={account}|tik!id0?low
    ={account}|tik!id0?high
     
    #10     Feb 9, 2006