Csharp forms dll
From OpenKM Documentation
Contents |
DLL have been compiled for net 2.0 that should ensure go with any upper .net version |
OKMForm DLL library has general purpose forms to help work with OpenKM.
Understanding the basics
- TreeForm ( tree navigator across taxonomy, templates and personal folder)
- SearchForm ( search form across taxonomy, tamplates and personal folder )
- ConfigurationForm ( form to display OpenKM configuration parameters ).
TreeForm
TreeForm display navigator tree which can be switched between taxonomy, templates and personal context.
Button cancel or accept will fire treeButtonCancelled or treeButtonAccepted methods declared in TreeHandler.
TreeForm needs DictionaryHelper for UI translatiosn take a look at Csharp_utils_dll#DictionaryHelper |
Translations properties needed:
form.tree.title=Navigation tree
form.tree.context.root=Taxonomy
form.tree.context.templates=Templates
form.tree.context.personal=Personal
form.tree.contextmenu.newfolder=New folder
form.tree.contextmenu.renamefolder=Rename folder
form.tree.contextmenu.deletefolder=Delete folder
form.tree.button.accept=Sign
form.tree.input.title=Folder management
Example:
public class Example : TreeHandler {
public Example(Dictionary dictionry) {
TreeForm treeForm = new TreeForm(this, dictionary, Program.okmWebservice);
}
// showTree
public void showNavigatorTree() {
try
{
treeForm.setFirstTime(true);
treeForm.ShowDialog();
}
catch (Exception e)
{
Logger.Instance.error("treeForm", e);
}
}
// treeButtonCancelled
public void treeButtonCancelled()
{
// something to do here
}
//treeButtonAccepted
public void treeButtonAccepted(String fldPath, String fldUuid)
{
// something to do here
}
}