There is no WebPage opened as the WebDialog is displayed in the Session Open Event. I had tried using javascript but it seems still display a value of 0.
Alvin, controls such as WebDialogs are composed of several elements. What you do here with your JavaScript is get the coordinates of the grey overlay. To get the actual webdialog, you must get to the element inside.
Use the browser developers tools to see the elements corresponding. I suggest Chrome which is IMHO the best because it outlines elements as you go through the code.
There is no WebPage opened as the WebDialog is displayed in the Session Open Event. I had tried using javascript but it seems still display a value of 0.
Give a man a fish and he eats for one day. Teach him to fish and he will eat his whole life.
Try to look at your dialog with the developer tools, to see how and where that value is found. I could have given it to you as well, but I think you will develop much more powerful skills if you learn how to explore the DOM.
[quote=308964:@Michel Bujardet]Alvin, controls such as WebDialogs are composed of several elements. What you do here with your JavaScript is get the coordinates of the grey overlay. To get the actual webdialog, you must get to the element inside.
Use the browser developers tools to see the elements corresponding. I suggest Chrome which is IMHO the best because it outlines elements as you go through the code.[/quote]
I have start learning to fishing for almost 2 weeks. So I am still “green” in this area. Please bear with me. Thank you for your comments and concerns. Without helpful guys like you and the rest, I think I won’t be able to survive in this area.
Alvin, what you found is the CSS values apparently.
What you want to do is to explore the elements of the body, until you find the element. Here is a screen shot of what I am talking about. See the dialog on the left in blue because the code is selected, and on the right, the dialog element _body.
Click on the small pic to see full size
We all started some time. I see that you want to learn. You are doing great. Seeing you already exploring JavaScript was a very good surprise. Keep up the good work