FlashPlayerControl Help >> Access to Native Flash ActiveX Interface >> Methods

SetVariable

Description

Sets the value of the Flash variable specified by name to the value. Type of both arguments is string.

Message

FPCM_SETVARIABLE

Structure

struct SFPCSetVariable
{    
     // [in]
     struct
     {
          LPCTSTR lpszBuffer;

     } name;

     // [in]
     struct
     {
          LPCTSTR lpszBuffer;

     } value;


     // [out]
     HRESULT hr;
};

Example

void InvokeSetVariable(HWND hwndFlashPlayerControl, LPCTSTR name, LPCTSTR value)
{
     SFPCSetVariable info;

     info.name.lpszBuffer = name;
     info.value.lpszBuffer = value;

     ::SendMessage(hwndFlashPlayerControl, FPCM_SETVARIABLE, 0, (LPARAM)&info);
    
     if FAILED(info.hr)
          // Error
     {
          // ...
     }
     else
          // OK
     {
          // ...
     }
}

Flash versions

5: supported
6: supported
7: supported


Copyright © 2004 Softanics. All rights reserved.
Delphi is a trademark of Borland Software Corporation.
Macromedia and Shockwave Flash are trademarks of Macromedia, Inc.