accessing a javascript variable using IHTMLDocument

Discussion in 'Javascript' started by Alf, May 20, 2004.

  1. Alf

    Alf Guest

    Hi,

    I have the IHTMLDocument2 interface set up for a web page in an MFC VC++
    prog.
    eg

    IHTMLDocument2* pHTMLDocument2;
    hr = pMC->QueryInterface(IID_IHTMLDocument2,
    (void**)&pHTMLDocument2 );

    The page contains:
    var variable_name = "variable data";
    within a <SCRIPT> tag.
    Is there a straightforward way to return the value of the variable_name
    using the interface?

    Of course I know I can do a hard-coded search using, say, 'c' char
    functions, but I just wondered...

    TIA

    BTW
    Apologies if this is the wrong forum - please redirect me as appropriate.
     
    Alf, May 20, 2004
    #1
    1. Advertisements

  2. Alf

    kaeli Guest

    kaeli, May 20, 2004
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mohanasundaram
    Replies:
    44
    Views:
    1,458
    Keith Thompson
    Aug 24, 2004
  2. mfglinux
    Replies:
    11
    Views:
    962
    Roberto Bonvallet
    Sep 12, 2007
  3. Jonas Daunoravicius
    Replies:
    5
    Views:
    512
    Peter
    Jul 17, 2003
  4. Rags
    Replies:
    1
    Views:
    143
    William Morris
    Apr 6, 2004
  5. Jonas Daunoravicius
    Replies:
    5
    Views:
    472
    Peter
    Jul 17, 2003
  6. David Filmer
    Replies:
    19
    Views:
    502
    Kevin Collins
    May 21, 2004
  7. whidbeywave
    Replies:
    3
    Views:
    270
    whidbeywave
    Jan 16, 2006
  8. Replies:
    6
    Views:
    220
    Bart Van der Donck
    Aug 19, 2006
Loading...