Hello Amin,
I don't know what you want to do, but I would call such a function by
registering an event listener on the window that contains the xul code.
For example:
function setLabel() {
window.removeEventListener('load', setLabel, false); // must contain
the same signature!
var text = "";
// here define the label text e.g. by calling another functions or so
document.getElementById('labelID').value = text;
}
window.addEventListener('load', setLabel, false);
NOTE that this event listener declaration must be located at the end of
a javascript file after(!) the declaration of the function it has to call.
I hope that wasn't so confusing it looks like.
Good luck
Daniel
Amin wrote:
> hi
>
> document.getElementById('labelID').value = MyFunction
>
> is there any place to put this code except onload ?
>
> On 2/7/07, *Daniel Muenter * <[EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]>> wrote:
>
> Hi,
>
> would you declare an id for this label you could change the value by
> reference like
>
> document.getElementById('labelID').value = "something";
>
> Daniel
>
>
>
> Amin wrote:
> > hello
> >
> > any body know how to replace "here!!!!!!!" with a function that is
> > defined in Update.js
> >
> > <script
> > type="application/x-javascript"
> > src="chrome://inbasicph/content/Update.js"
> > />
> >
> > <label value="here!!!!!!!" style="font-weight: Bold; " />
> >
> ------------------------------------------------------------------------
> >
> > _______________________________________________
> > Project_owners mailing list
> > [email protected] <mailto:[email protected]>
> > http://mozdev.org/mailman/listinfo/project_owners
> <http://mozdev.org/mailman/listinfo/project_owners>
> >
>
> _______________________________________________
> Project_owners mailing list
> [email protected] <mailto:[email protected]>
> http://mozdev.org/mailman/listinfo/project_owners
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Project_owners mailing list
> [email protected]
> http://mozdev.org/mailman/listinfo/project_owners
>
_______________________________________________
Project_owners mailing list
[email protected]
http://mozdev.org/mailman/listinfo/project_owners