15.08.2013 Views

Ektron® eWebEditPro Developer's Reference Guide

Ektron® eWebEditPro Developer's Reference Guide

Ektron® eWebEditPro Developer's Reference Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Displaying WebImageFX<br />

{<br />

WebImageFX<br />

<strong>eWebEditPro</strong>.instances[sEditorName].editor.ExecCommand("cmdmfueditim<br />

age", "", 0);<br />

}<br />

See Also: “Method: IsVisible” on page 79<br />

Because the display of WebImageFX within <strong>eWebEditPro</strong> is a function of<br />

<strong>eWebEditPro</strong>, you must use <strong>eWebEditPro</strong>’s command mechanism to display the<br />

feature to the user. Use the cmdmfueditimage command to make the editor<br />

visible.<br />

<strong>eWebEditPro</strong>.instances[sEditorName].editor.ExecCommand("cmdmfueditimage", "", 0);<br />

You can determine if WebImageFX is already displayed by using the isVisible<br />

method. If it is, sending the command hides WebImageFX. Here is how to check<br />

WebImageFX’s display status.<br />

if(false == objImageEdit.IsVisible())<br />

{<br />

<strong>eWebEditPro</strong>.instances[sEditorName].editor.ExecCommand("cmdmfueditimage", "", 0);<br />

}<br />

Controlling WebImageFX<br />

Full Example<br />

See Also: ”Method: IsVisible” on page 79<br />

Once the WebImageFX object is obtained and the feature is available, you can<br />

control functionality through the object. Below is an example method call that<br />

displays the Save As image dialog.<br />

objImageEdit.AskSaveAs();<br />

See Also: ”Method: AskSaveAs” on page 47<br />

Below is a full example that performs all of the object retrieval and error checking<br />

to produce the Save As dialog in WebImageFX.<br />

<strong>Ektron®</strong> <strong>eWebEditPro</strong> Developer’s <strong>Reference</strong> <strong>Guide</strong>, Release 5.1, Revision 1 512

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!