Starter vbScript

How do I get started using Dumont?

At this point in time Dumont cannot hook itself in to the running vbScript program. This is something we (me, myself and I) will be working on in the future. Therefore, in the meantime, you, the programmer, must tell Dumont when things are happening on your form. By making calls into Dumont, coincident with the standard vbScript Commence events, Dumont will then be able to perform its internal processing functions on the form and fields.

Here is a copy of a starter script I use in all my beginning forms. It provides all the basic Dumont hooks ready for the meat of my application.

vbScript Example:
 $OBJECT=Form
 Option Explicit
 
 dim ddll: set ddll = createObject("DumontDLL")
 dim dfrm: set dfrm = ddll.Form(Form)
 
 Sub Form_OnLoad()
   dfrm.onLoad
 End Sub
 
 Sub Form_OnSave()
   dfrm.onSave
 End Sub
 
 Sub Form_OnCancel()
   dfrm.onCancel
 End Sub
 
 Sub Form_OnEnterTab(ByVal TabName)
   dfrm.onEnterTab TabName
 End Sub
 
 Sub Form_OnLeaveTab(ByVal TabName)
   dfrm.onLeaveTab TabName
 End Sub
 
 Sub Form_OnEnterField(ByVal FieldName)
   dfrm.onEnterField FieldName
 End Sub
 
 Sub Form_OnLeaveField(ByVal FieldName)
   '
   ' when onLeaveField returns true it means something changed
   '  on the field we just left (are just leaving).  We have a 
   '  chance to do some post-edit processing.
   '
   if( dfrm.onLeaveField(FieldName) ) then _ 
     Form_onChangeField FieldName
 End Sub
 
 Sub Form_OnChangeField(ByVal FieldName)
   ddll.debug dfrm.Field(FieldName).ChangeLog
 End Sub
 
 Sub Form_OnActiveXControlEvent(ByVal ControlName, ByVal EventName, ByVal ParameterArray)
   dfrm.onActiveXControlEvent ControlName, EventName, ParameterArray
 End Sub




~ ~ ~ ~ ~ ~
Source Code without Comments is like a Cranberry Garland
without the berries. Comment your Code!
 
Commence Database User Support Group Forum
http://newsgroup.showoff-db.org/
~ ~ ~ ~ ~ ~
Author: Mark Petryk
Lorimark Solutions, LLC
mark@lorimarksolutions.com