Announcement

Collapse
No announcement yet.

Vista: No Historic Data Till Second Request

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Vista: No Historic Data Till Second Request

    Trying to transition to Vista (and from office 2003 to office 2007). My code that attempts to compute daily moving volume average by using the desktop api via excel VB worked fine. But under Vista/2007 the first time I request the data I get nothing. The second time I request (i.e. repeat for the same symbol) I get the data. Any thoughts on why this is happening? Would prefer to avoid performance hit of requesting data twice.
    Thanks!
    Lin

  • #2
    Is there a chance this is an artifact of a faster computer?

    As I noted elsewhere, you may be getting an OnBarsChanged event before the return from RequestHistory. You might consider using globals that can be checked at both points. If you get an OnBarsChanged and can determine that it's time for further processing, you can set a flag the deters any action that otherwise would occur following return from RequestHistory (and, vice versa). This is ugly, but it may be better than enduring another wait state that you may have in effect. So far, I've seen very few situations where a return from RequestHistory is not a valid handle using Vista.

    I don't know whether Office 2007 could be causing what you see. I still use Office 2003 with Vista.

    Bill

    Comment

    Working...
    X