#11 Error executing sample program


I have succefully built TriXUL on win xp machine..
I have also run some XUL examples .They are working fine..
But there is problem with one example..box.xul..
Method Button1Click(); does not seem to work..

it gives an error like

In EnabledPropertySetter, found an element!!!
In EnabledPropertySetter, it's a control!!!
In DoSetValue!!!
In DoSetValue, found an element!!!
In DoSetValue, it's a control!!!
In ValuePropertyGetter!!!
In ValuePropertyGetter, found an element!!!
In ValuePropertySetter!!!
In ValuePropertySetter, found an element!!!
In DoSetValue, it's a control!!!
Button::ButtonPressed fail

Maybe it is because of this line
var obj = document.getElementById("text1");
var component = componentmgr.getComponent("94981D9E-FC99-11D9-8BDE-F66BAD1E3F3A");
because if i set another method to invoke on button click like MenuFileOpen();
It gets executed without an error!!


  • Syd Logan

    Syd Logan - 2007-11-27
    • priority: 5 --> 3
    • assigned_to: nobody --> prafulla_t
  • Nobody/Anonymous

    Logged In: NO

    I think..
    If getElementById fails, because of non-existence of element with specified id ( text1 does not get assigned to first textbox by default, nor does button1, to first button.. We have to specify it).., the JS code which follows it, does not get executed..
    I think we need to modify Document::DoGetElementById() method.. because when this method reture JS_FALSE, the script execution stops at that location..
    Is this what is expected?

    In normal browser application, it does not happen so..
    E.g Suppose we dont have any element with id = nameTextBox. still following code is perfectly valid..

    var element = document.getElementbyId("nameTextBox");
    if (element) {

    in the case of TriXUl JS Interpretation engine, the code execution will stop at getElementbyId only..
    I am ready to fix this..
    I just wanna know what you think about it..

    -- Prafulla

  • Syd Logan

    Syd Logan - 2007-12-28

    Logged In: YES
    Originator: NO

    This is simply because the JS file simple.js is not really appropriate anymore for box.xul. There are a few problems -- one being there is no element in the document with "text1" as an ID. Second, there is no C++ component with the specified class ID in your components directory.

    So, one fix would be to come up with a box.js that is appropriate for box.xul, and check that in (making sure that box.xul is modified to use it, instead of simple.js).

  • Syd Logan

    Syd Logan - 2007-12-28
    • priority: 3 --> 2

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks