Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 662411
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T23:22:32+00:00 2026-05-13T23:22:32+00:00

When i call window.open, I can include a list of parameters. One of these

  • 0

When i call window.open, I can include a list of parameters. One of these paramaters is scrollbars, which can be set to yes or no.

When I put javascript in the child window, the javascript needs to detect if scrollbars were set to yes or no when the window was opened. I want to know if the window has scrollbars enabled by default or not.

I only care about doing this in IE. How do I check? window.scroolbar does not work in IE.

How do I do this? To be perfectly clear, I’m not talking about div overflows, I’m talking about the scrollbar property of the window.

edit:
– I am in IE so window.scrollbars/this.scrollbars won’t return anything
– The windows scrollbars exist outside the body.
– Looking at the document’s width will tell me about the document. I can even figure out if there are scrollbars in the document. This will not tell me anything about the window itself.
– The width of the window’s scrollbar changes dependent on what the currently selected Windows Desktop Theme is, for ascetic reasons.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T23:22:32+00:00Added an answer on May 13, 2026 at 11:22 pm

    You can determine if the window has a visible scrollbar in IE by using this little JavaScript trick:

    //You'll have to modify this so as not to do it unless your user is running IE
    window.attachEvent('onload', getChrome);
    
    function getChrome() {
        //read the window width and height
        var w = document.documentElement.clientWidth;
        var h = document.documentElement.clientHeight;
    
        //set the window to that size
        window.resizeTo(w, h);
    
        //read the window width and height again
        var newW = document.documentElement.clientWidth;
        var newH = document.documentElement.clientHeight;
    
        //calculate the difference
        var diffX = w - newW;
        var diffY = h - newH;
    
        //set the window back to what it was
        window.resizeBy(diffX, diffY);
    
        alert('diffX: ' + diffX + '\ndiffY: ' + diffY);
    
        //If diffX is larger than 10 (in Vista and Windows 7, the borders are 5px each)
        //then you're scrollbar is visible.
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

So I have a call in one window to a window.open() for a different
I can open a new window using window.open() in ExternalInterface.call() but then I want
With window.open method I open new site with parameters, which I have to pass
I have a few buttons in my script that call window.open('myUploadScript.php?arguments=test...',''). I'm passing querystring
Possible Duplicate: JavaScript open in a new window, not tab How can I open
I want open window.open as modal popup. var features = 'resizable= yes; status= no;
I would like to call from javascript window.open(< full URL to my '/controller/action/id' >,
I'm using global variables to pass around a response from a AJAX call: window.response
What is the purpose of the Call Stack window in Visual Studio?
I'm using the $(window).scroll(); to specify a function to be call for when the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.