C# - First Application
|[Top] [Chapter] [Previous] [Next]|
We create a new empty project and add the TextDynamic control. We also add a menu control and a status bar with 4 sub panels.
Also required is a reference to the WPDynamic namespace:
When the application runs it will look like
Now we want to add a toolbar. We use the SetLayout method to load the PCC file. We use the standard buttons.PCC file - it is in the same directory as the kernel DLL.
With licensed version please make sure you call wpdllInt1.EditorStart with your license name/key before doing anything else. The license information is confidential and must not be made visible in the application.
public partial class Form1 : Form
// Initialize the Editor
// Set your License key:
// Load the PCC file (no password)
// Initialize the editor
// as single editor (no splitscreen)
// with 16x16 toolbar (for 24x24 use wpmodexToolbarLG)
// and PDF, Spellcheck and table support.
// Select the GUI elements ruler, scrollbars and
// the lower left panel to change zooming and layout
// We have no second editor window, so use wpguiDontSet
At runtime the application now looks like
Now we can already load text. Even the PDF export works. (The demo version includes all options - in the full version options such as spellcheck, PDF, reporting are optional). Table support is always included.
To remove certain elements off the toolbar edit the PCC file using the Package File Manager.