Manage Learn to apply best practices and optimize your operations.

Controlling Web window settings when opening a document from a view

This tip describes how to control Web window settings when opening a document from a view.

This code snippet allows you to open a URL from an HTML view (not applet views)into a window where you can control the size, position, toolbar, menu, etc.


Place the following Javascript in the JSHeader of the $$ViewTemplateDefault form or any form where there is an embedded view.

 function openBrWindow(theURL,winName,features) { window.open(theURL,winName,features); } In the column formula that you would like to use as the link, use any one of the following
formulas: (where DocID is a field on the document that holds the Document UNID and Subject is a
descriptive field on the document) "[<a href="#" onClick="openBrWindow('http://server.microchip.com/mydb.nsf/0/" + DocID +
"?openDocument','Name','')">" + Subject + "</a>]" "[<a href="#" onClick="openBrWindow('../mydb.nsf/0/" + DocID +
"?openDocument','Name','')">" + Subject + "</a>]" "[<a href="#" onClick="openBrWindow('../mydb.nsf/0/" + DocID + "?openDocument','Name','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes
,resizable=no,copyhistory=yes,
left=300,top=150,screenX=300,screenY=150,width=600,height=400')
">" + Subject + "</a>]" The additional parameters beginning with toolbar=no control the look and feel of the window that
is opened. (screenX and screenY control the positioning on the screen for Netscape
Navigator, left and top work with IE 4.0 and above.)
This was last published in December 2002

Dig Deeper on Domino Resources - Part 3

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

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

SearchExchange

SearchContentManagement

Close