|
I can't, thats against company policy. And I know it won't exist until I create it, that is why I was asked to create an Exist method to prevent the use of an non-existant object.
What I can say is that the code looks like:
ButtonObject = {
MakeTheButton: function(){code}
TheClickMethod: function(){code}
}
I need to know if the ButtonObject exists yet by passing it, or its name into a function I made. However if I try Exists(object) it breaks as it passes by reference, so as of now I think I can only pass its name as a string.
I did find out about eval('Theobject'), but it looks like most people don't like it, that and if the object doesnt exist it throws a script error of undefined. Which is weird...but anyway
|