0

zk.wpd JS error, with window inside window

asked 2015-03-18 05:16:24 +0800

echarish gravatar image echarish flag of Japan
1809 7
http://jp.linkedin.com/in...

updated 2015-03-18 05:20:06 +0800

I am gettting JS errors on zk.wpd

TypeError: Cannot read property 'offsetHeight' of null

Failed to mount: Cannot read property 'offsetHeight' of null

TypeError: ao is null

in zk.wpd script file

I have narrowed it down to a cause... that is I have a zul page where i have created a child window to be opened as a popup i.e. initially hidden, inside an parent window, but for some reason it works properly for few times and than all of a sudden it starts to throw strange JS errors from zk.wpd as i mentioned in my initial question.

If i comment the child window and run application, there is no issue at all.

I can't understand as of now, why it is happening but will update this post again if I find a solution.

the child window is

<window id="filterAccidentWindow" border="normal" style="left: 850px; top: 40px"  visible="true" width="200px" closable="true">
    <caption label="${c:l('FILTER')}" width="180px"/>
         <grid hflex="1">
            <rows>
                <row><label hflex="1" sclass="font12B" value="${c:l('Contract.inquiry.accident.date')}"/></row>
                <row><filterdatebox hflex="1" filterManager="${arg.manager.filterManager}" property="filterAccidentDate"/></row>
                <row><label hflex="1" sclass="font12B" value="${c:l('Contract.inquiry.accident.number')}"/></row>
                <row><filtertextbox hflex="1" filterManager="${arg.manager.filterManager}" property="filterAccidentNumberCode"/></row>
                <row>
                  <hbox hflex="1">
                    <actionbutton image="/images/filter.gif" label="${c:l('APPLY')}" associateAction="${arg.manager.filterManager.applyAction}"/>
                    <actionbutton image="/images/cancel.gif" label="${c:l('RESET')}" associateAction="${arg.manager.filterManager.resetAction}"/>
                  </hbox>
                </row>
            </rows>
        </grid>
</window>

it is a part of parent window with few other grids and listboxes

<window border="normal" visible="false" width="800px" closable="true" onClose="windowManager.closeWindow(event)"
 contentStyle="overflow-x:hidden;overflow-y:auto;position:relative" id="contractAccidentClaimWindow">

CHILD WINDOW GOES HERE ALONG WITH OTHER GRIDS AND OTHER tags </window>

delete flag offensive retag edit

Comments

set your hidden window not hidden, I'm thinking in the way that the hidden window stay's open while the parent window is closed, and test like that a few times.

chillworld ( 2015-03-18 07:23:33 +0800 )edit

If i keep it not hidden, than i face no issues, but as for my requirement i have to hide it and open it onclik of button action, can you suggest me why am i getting the error and how to resolve it.

echarish ( 2015-03-23 02:28:29 +0800 )edit
Be the first one to answer this question!
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
2 followers

RSS

Stats

Asked: 2015-03-18 05:16:24 +0800

Seen: 21 times

Last updated: Mar 18 '15

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More