Q

Selecting a document and getting it to open in a browser

Can you help a beginning developer? I have a view in the Notes client. When I select a document it opens in another tab. When you select a document to open it, is there a way so that it opens in a browser?

Yes, assuming the application is available on a Domino server with HTTP task-enabled. However, I have to wonder why, when you have the Notes client available, you would want to use a Web browser to open the document. You might want to think about ways to do in the Notes client whatever it is you're using the browser for now.

Anyway, to open a browser window in lieu of the Notes document, you need to code in an event that will notice the user trying to open the document, and do something else instead. This code may either be in the Queryopen event of the form (if you want it to do this from every view) or in the Queryopendocument event of the view (if you only want to have it happen in a particular view). In either case, you would use the statement Continue = False, which is the signal to Notes to not go ahead with opening the document, and then use NotesUIWorkspace.URLOpen method to open the browser window and display the document in it.

Of course you will need to compute the URL of the Notes document. In the simplest case you can use the NotesDocument.HttpURL property for this, but if you're trying to do it from a replica other than the one on the Domino server you are "browsing" on, you'll have to compute the URL using an expression such as "http://server/yourdb.nsf/0" & doc.UniversalID & "?OpenDocument."

Do you have comments on this Ask the Expert question and response? Let us know.

This was first published in April 2005

Dig deeper on Web Development for Lotus Notes Domino

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.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchWinIT

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 ...

SearchEnterpriseLinux

SearchVirtualDataCentre.co.UK

Close