About Registration Send E-mail to author

Smart HTML Editor Quick Start - Step 4

[Step 1] [Step 2] [Step 3] [Step 4] [Step 5]

Press "CTRL+E" to show Pascal Script Editor, then press "CTRL+N" to create new script. In the scripts editor type the following:

Program OperaPreview;
var s: string;
    sf: TSF;
function WinExec(lpCmdLine: PChar; uCmdShow: longword): longword; 
  external 'WinExec@kernel32.dll stdcall';
const
  SW_SHOW = 5;
Begin
  sf:=TSF.Create;
  if sf.GetEditorFileName<>'NONAME' then
    begin
      EditorLines.SaveToFile(sf.GetEditorFileName);
      s:='c:/program files/opera/opera.exe '+sf.GetEditorFileName;
      WinExec(PChar(s), SW_SHOW);
    end  
    else sf.ShowMsg('Save the file first!');
  sf.Free;
End.   
OperaPrewiew script into Scripts Panel

Press "CTRL+S" and save the file as OperaPreview.ps, press "ESC" to return into Smart HTML Editor Main Window, in the Scripts Panel you can see line with "OperaPrewiew.ps", double click on it and run Opera with file prewiew. You can close or minimize Opera window to return into the Smart HTML Editor.

Now, we are ready to go to the next step - step 5, where you can see some words about registration of Smart HTML Editor.

Copyright © Dmitry Spitsyn, 2007

[Step 1] [Step 2] [Step 3] [Step 4] [Step 5]

Sponsors: