• Browse Blogs
  • My Blog
  • My Updates

+Tags Get help with tags?

  • View as cloud  | list

+ Similar Entries

photo

Bringing The Power O...

Blog:  Beyond The Ye...
Peter Presnell
Updated 
No RatingsRatings 0     No CommentsComments 0
photo

Adding the "X" Facto...

Blog:  Beyond The Ye...
Peter Presnell
Updated 
No RatingsRatings 0     CommentsComments 2
photo

Tagging Design Eleme...

Blog:  Beyond The Ye...
Peter Presnell
Updated 
No RatingsRatings 0     CommentsComments 1
photo

Add Discussion Threa...

Blog:  Beyond The Ye...
Peter Presnell
Updated 
No RatingsRatings 0     CommentsComments 2
photo

New Video Includes S...

Blog:  Beyond The Ye...
Peter Presnell
Updated 
No RatingsRatings 0     No CommentsComments 0

+ Bookmarks

+ Blog Authors  

Programming Events In both @Language and LotusScript

Peter Presnell |   | Tags:  .dominoframework | Comments (0)  |  Visits (578)

Have you ever wished it was possible to program an event such as QuerySave in both @Language and LotusScript?  Sometimes the most efficient (or only) way to perform a specific task is to code the event using @Formula and @Commands.  That works fine until a request comes along in which LotusScript is the only solution.  Using Evaluate within LotusScript  can sometimes be a solution but there is another way to achieve this.

 

1) Create a class

2) In the constructor for the class create an event handler for the event and set it to invoke a sub of that class

3) Create the method using the same signature as the event with the LotusScript code and put all the LotusScript code in there

4) In the QueryOpen event create an instance of the class passing the NotesUI object (this can be any event invoked prior to the called event - QueryOpen is usually the first and is usually the best)

5) Place the @Language component in the actual event on the form/page.view

 

When the event is fired the @Language coded in the the actual event will be executed and then the eventhandler coded in the class will be executed....

 

Form example:

 

Class MyClass

  Sub New(Source As NotuesUIDocument)

    On Event QuerySave From Source Call OnQuerySaave

  End Sub

 

  Sub OnQuerySave(Source as NotesUIDocument,Continue As Variant)

  ' Place all LS QuerySave code here

  End Sub

End Class

 

Dim Var As MyClass

 

Sub QueryOpen(Source As NotesUIDocument)

  Set Var = New MyClass(Source)

End Sub

No RatingsRatings 0

Comments (0)

There are no comments to display Add a Comment Add a Comment

Previous |  Main  | Next
Skip to main content link. Accesskey S
IBM Lotus Connections Help Tools About