I need to get the window width and height in Internet Explorer
Initially I was using a nice simple statement var height = HtmlPage.Window.Eval("innerHeight").ToString();
However I then found out that this doesnt work in IE 8
There appear to be loads of different ways to get the width and height of a window, I am not sure which is the best, but the one below is mentioned here Get the window height
doc = document; var theHeight = Math.max( doc.body.scrollHeight, doc.documentElement.scrollHeight, doc.body.offsetHeight, doc.documentElement.offsetHeight, doc.body.clientHeight, doc.documentElement.clientHeight );
My question is how can I put this into Window.Eval to get the height?
What does the syntax need to be?
If there is a better, more reliable way of getting window width and height please let me know, but it needs to work for different browsers
Paul