Syntax
FilePreview HorizPos, VertPos, Width, Height, .Identifier
Remarks
Creates a file preview box — similar to the one in the Find File dialog box (File menu) — in a custom dialog box. A custom dialog box can have only one file preview box.
You cannot use the Dialog Editor to create a FilePreview instruction. A good workaround is to use another control as a stand-in. In the Dialog Editor, size and position the stand-in control as you want the file preview box to be sized and positioned. Then, after you paste the dialog box definition into your macro, convert the stand-in instruction to a FilePreview instruction.
The file preview box displays the first page of the document that is active when the dialog box is displayed. You can also control which document is displayed in the file preview box by using DlgFilePreview in a dialog function. For information about using a dialog function, see Chapter 5, "Working with Custom Dialog Boxes," in Part 1, "Learning WordBasic."
Argument | Explanation |
HorizPos, VertPos | The horizontal and vertical distance of the upper-left corner of the file preview box from the upper-left corner of the dialog box, in increments of 1/8 and 1/12 of the System font (Windows) or the dialog font (Macintosh). |
Width, Height | The width and height of the file preview box, in increments of 1/8 and 1/12 of the System font (Windows) or the dialog font (Macintosh). |
.Identifier | An identifier used by a DlgFilePreview instruction in a dialog function to change the document displayed in the file preview box. |
For an example, see DlgUpdateFilePreview.
See Also
DlgFilePreview, DlgUpdateFilePreview, Picture