/ Forums / Advansys Formativ / Creating Solutions with Formativ / How can I open a find windows and search for a specified string

  • Creator
    Topic
  • #4317
    jhillenb
    Participant

    Hello,

    how can I open a – FIND – Window in GW and search for a specified string variable. This variable should be ” filled ” by a external Windows application. The script should be triggered by this application, too.

    Example: external application stores a eMail address in a environment variable and call Formativ script. In GW it opens the find window and search for the specified email address and display result window.

    Please be kind enough to give me some ideas..

    Thanks a lot.
    Best regards.
    Juergen Hillenbrand
    BIT Informationssysteme

  • Author
    Replies
  • #7805
    lp_irovetz
    Participant

    Hi,

    In your post you said that your application ‘open a find windows’ to search.

    I think you don’t need to ‘open’ but just make a .find request in the address book with GW Object API.

    Warning .find for an eMail Adresse in systeme adressbook don’t work in all version of GW Client. (OK < 6.5.4 for now)

    Could you precise you script ?

    L.P. Irovetz
    Arcane GroupWare

    #7804
    jhillenb
    Participant

    Hi and thanks for your quick response.

    Lets try to explain better 😉

    The script should search for all eMails which was received or send to a specified eMailadress. So the GW find result window should show up these mails.

    The specified eMail address was delivered by other windows application and should trigger the script which opens the GW search result window.

    Best regards
    J.Hillenbrand

    #7806
    Support 3
    Participant

    You can use the GroupWise Query to display the search results with a query folder.

    Your external application can call the Formativ script which will create the query folder if not exists and select the folder. You can set the StartOnOpen properties of the query folder to automatically start the query when the query folder is opened.

    See the Object API (http://developer.novell.com/documentation/gwobjapi/index.html?gwobjenu/data/h7ikbsqg.html) for more information. Here is some details of the Query:

    quote:


    Query

    Provides query information and actions. This object can represent either a stand-alone query (which does not persist in the message database) or a query associated with a query folder (which does persist in the message database).
    Properties

    The following table lists properties along with their access and descriptions.

    Property

    Application R/O Application. The Application object.

    Completed R/O Boolean. TRUE if the query has finished or has never before been started. FALSE if the query is still executing. When logged into a remote database, a running query will not complete until the user synchronizes (downloads) the query results.

    CompletionDate R/O Date. The date and time the query was last completed, or if the query is still in progress, the date and time of the last update.

    Expression R/W DEFAULT. String. The filter expression to be matched. This can be set to NULL or an empty string (“”). In either case, no filtering will be applied to the query. See Section 5.0, Filter Expressions .

    Locations R/O Locations collection. The locations to be searched. Can contain Account, DocumentLibrary, and Folder objects.

    Parent R/O Object. The Account object (for stand-alone queries) or Folder object (for query folders) that owns this object.

    QueryMessages R/O MessageList. The messages that match the filter expression. Returns snapshots of the partial results if Completed = FALSE, or the final results if Completed = TRUE.

    SearchLocally R/W Boolean. TRUE means execute the search locally, FALSE means execute the search on the master system (applies only when running Remote).

    StartOnOpen R/W Boolean. TRUE means the client will automatically start the query when the query folder is opened. Affects only client behavior. Object API behavior is unaffected because folder objects are not opened.

    Methods
    Folder CreateFolder(String FolderName, [Folder ParentFolder])
    Creates a new query folder based on this query. The new folder will have its own private query instance. FolderName is the name of the new folder. ParentFolder is the folder in which the new folder is created; if omitted, the new folder is created in the root folder. Returns the new folder.

    Refresh()
    Forces this Query object to reread property values from the message database.

    * If this Query object belongs to a query folder, the folder’s Messages collection is not refreshed (consider refreshing the folder instead). Use this method to obtain a new snapshot while the query is executing.
    * If the Query object belongs to a query folder, it is also refreshed when its owning Folder object is refreshed.
    * If the Query object is a stand-alone query, it is not refreshed when its owning Account object is refreshed.

    The actual reading of a specific property may be postponed until the next time the property is accessed. This “lazy evaluation” is an optimization that avoids unnecessary reading of unaccessed properties. Because Refresh may be used to update the Completed property, the reading of the QueryMessages property should be postponed. The CompletionDate and QueryMessages properties must be in sync (they must be read as simultaneously as possible).

    Start()
    Starts execution of the query. Sets Completed to FALSE and causes the QueryMessages property, or the parent folder’s Messages collection, to start returning partial results.

    Stop()
    Stops execution of the query. It issues a HALT command to the GroupWise Search Engine. The HALT is handled the next time a set of Search Results is returned. The Stop method does not set the Query.Completed flag to TRUE. You can take the current set of found messaages and start using them.

    This method is available only in GroupWise 5.5 and later versions.


    Regards,
    Advansys Support

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.