0

failed to utilize getTop(), getLeft() on div(component). Please help.

asked 2018-12-28 14:31:18 +0800

cindy951357 gravatar image cindy951357
3 2

Hello. I am trying to get the html(zul) position of the component. I found getTop and getLeft in the zk library; however, while the getId() is working in the below code, the getTop(and getLeft) functions are not working; they return null. The currentDiv is of type ArrayList

.

    Connection conn = DaoDataSource.getConnection();
    for(int i =0;i<currentDiv.size();i++) { 
        Div ithDiv = currentDiv.get(i);
        String query = "UPDATE "+tablename+" SET LEFT ="+ithDiv.getLeft()+",Top="+ithDiv.getTop()+" WHERE ID = "
    +ithDiv.getId().split("-")[1]; 
        System.out.println(query);
        Statement st = conn.createStatement();
        ResultSet rs = st.executeQuery(query);
        rs.close(); 
    }

The following code is regarding to the creation at viewModel. Div tmpdiv = new Div(); tmpdiv.setId(myUtil.monitorholderString+currentId);

delete flag offensive retag edit
Be the first one to reply this discussion!
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
1 follower

RSS

Stats

Asked: 2018-12-28 14:31:18 +0800

Seen: 4 times

Last updated: Dec 28 '18

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