Atozed Forums

Full Version: IWLocker How To?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Howdy All!

I have some places where I need to lock the form and so I have functions that basically implement the following (c++):

void ActivateFormLock(void)
{
  UnicodeString strJS = L"ActivateLock();";

  // Add java script to be executed!
  WebApplication->CallBackResponse->AddJavaScriptToExecute(strJS);
}


void ReleaseFormLock(void)
{
  // Javascript to lock form
  UnicodeString strJS = L"ReleaseLock();";

  // Add java script to be executed!
  WebApplication->CallBackResponse->AddJavaScriptToExecute(strJS);
}

The problem is the IWLocker isn't activated. What am I doing WRONG?

Thanks in advance,

Shane
Hi Shane,

Usually I'll put 'AcivateLock();' in the client js event so it gets locked immediately then this will release after returning from the server:

WebApplication->CallBackResponse->AddJavaScriptToExecuteAsCDATA("ReleaseLock();");


Regards,
Mark