4 Replies Latest reply on Feb 4, 2009 11:45 PM by Darren2

    Resize browser window on start-up

      Hi. Is there a way to resize the browser window so that it tightly fits my displayed application? Can the browser window size be defined in some configuration file? I've reduced the size of my MDI window settings which has left a gap on the right side of the browser window. I'd like to automatically adjust the broswer size to fit the new MDI size so that the user will not have to resize it manually.

      Any help would be greatly appreciated.
        • 1. Re: Resize browser window on start-up
          Michael Ferrante-Oracle
          You can use Java Script to resize the browser. However, why not try to do the reverse. Change the Applet size to use the entire browser space.

          In formsweb.cfg, make the following changes:


          This will cause the applet area within the browser to use all of the white with the exception of a small white frame that cannot be used.
          • 2. Re: Resize browser window on start-up
            Where would this java script be running from? It seems the browser size is already being set somewhere and I need to overwrite the current sizing? Any ideas?
            • 3. Re: Resize browser window on start-up
              Michael Ferrante-Oracle
              I don't understand your question, so let me restate my previous post.

              I am assuming that you are using separateFrame=false (in formsweb.cfg) for the purpose of my examples.

              Option 1*:
              Change the applet size which resides within the browser. Simply make the changes previously mentioned:


              Option 2*:
              If you prefer to change the browser, you can use java script. The java script would be added to the Forms baseXXX.htm file which is appropriate for your environment. If you use Oracle Jinitiator, you will need to add the scripting to basejini.htm and if you use the Sun JPI, you will need to edit basejpi.htm.

              The following script would be added to the HEAD section of the html

              function changeBrowserSize(w,h)
              *<noscript> JavaScript is not enabled in your Browser. </noscript>*

              In the BODY tag, add an ONLOAD event to make the change:

              *<BODY %HTMLbodyAttrs% onload="changeBrowserSize(800,810)">*

              You will need to set the width and height as needed. In the above example, they have been set to 800 and 810.
              • 4. Re: Resize browser window on start-up
                This wasn't my thread, but I've been searching for a solution to this issue myself.

                I tried your javascript and it works to resize the browser, however it would be better if Oracle didn't pick a fixed size to begin with (seems like 800x600). Is there a parameter in some configuration file somewhere that will tell Oracle to keep hands off the browser size?