Q
Problem solve Get help with specific problems with your technologies, process and projects.

Graphical buttons with mouseovers

What is the best way to use graphical buttons with mouseovers that execute @Functions or LotusScript in a Web-based Domino app? I've seen a few articles about it but they all seem to fall short.

I will typically use standard javascript to control the onmouseover change in the button graphic embedded in a form as "Pass-Thru HTML". Since there are many limitations on using @Functions from the web, I like passing the document unique ID to an agent as the Query_String and using the GetDocumentbyunid() to get a document. You can then do whatever you want to the document, format html from the agent or send a mail message. You could also create a new Document and display that using a meta tag 'refresh'. You can do just about anything once you're in the agent.

Example of the anchor link (usually a computed for display field) that is used when a user actually clicks on the button:

"[<a href="http://www.yourserver.com/your_db.nsf/your_agent?OpenAgent&" + @DocumentUniqueID + ">]" 

Example Lotus Script segment: 
        'get the value of the CGI variable "Query_String" 
        LineOfData$ = Doc.Query_String(0) 
        'The Query_String CGI looks something like: OpenAgent&3e320a07504ce76785256b61006ae53a 
        'the next line cuts off the 'OpenAgent&' so LineOfData$ then contains only the Document Unique ID 
        LineOfData$=Mid$(LineOfData$,11,Len(LineOfData$)) 
        'Then get the document 
        Set Doc = db.GetDocumentbyunid(LineOfData$)        

You now have the document and can display or modify any field, send mail etc.

If you need to just process some information and want the user to return to a view or form use the line below in the last line of your script:

        Print |<meta http-equiv="refresh" Content="0;url=https://www.yourserver.com/your_db.nsf/your_view?OpenView&ExpandView">| 

As always there are other ways to make this work. I usually rely on the above method because of the flexibility it affords.


Dig Deeper on Lotus Notes Domino Administration Tools

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchWindowsServer

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchDataCenter

SearchContentManagement

Close