Child Objects "Dead" - not responding

Hi guys,
This is driving me nuts ! I have a parent object which contains various buttons to manipulate an objects appearance -
Hue, Brightness, etc. Rather than setting mouse events for each button (with multiple scripts running), I'm taking advantage of the "Ex" feature "OnMouseEnterEX" to have one script running which handles the children in the parent script.
When I'm in DX builder, everthing works great ! When I create the widget, those buttons are "dead" not responding to their mouse events in the parent's code? I have tried everthing possible such as setting focus in code to ensure their availability, registering controller to reinforce trapping their events, etc. I've tried to solve this for days !
The funny thing is how it works fine in development mode but not on runtime !
I'm positive the parent - child relations are correct ( remember it works in the bulder).
As a stubborn coder, rarely do I "belly up" like this.
Please help
Joe
2,110 views 4 replies
Reply #1 Top
Followup FYI,

As a past and long time VB coder, it seems that DesktopX does not truly expose itself to VBScripting. This is a fact that I'm slowly learning & making adjustments accordingly when in the DesktopX environment. Try scripting API & you'll see what I mean ! Not a complaint actually, but just a learning experience to break some of my known VB scripting practises.

It seems (although I don't know why or fully understand), that if you render a parent object invisible from a child object in the same script, it has the same effect of actually closing that object and it's script even though the script is reported as running.

With much experimentation, I simply put the "button" (to hide) script (Object.visible = false)in another script object and called it from there. Works without fail 1000%. Why? - doesn't make sense, just fact.

Just thought you guys might be interested or made aware of. I'm trying to share my wealth of VB code snippets that I have written over the years for you DesktopX guys, but am finding that the coversion process to this environment is not as simple as I originally thought.

Thoughts - Ideas ?
Regards - Joe
Reply #2 Top
Hey there, try this
Make your parent object's 'Activation' to Default or rectangular or something. I'm betting it's on NONE. Then make your widget. I bet the buttons work now. There was an issue I remember where on widgetisation for some reason my child objects took on the activation of the parent. which if the parent was none, make all the other children none as well. but i think its been fixed. Or I could be wrong, and something else is doing it. but give it a try.


Posted via WinCustomize Browser/Stardock Central
Reply #3 Top
Thanx for reply JourneyMan,
I checked the activation as suggested on the parent object, and it was already on Default. Since I "solved" the problem with my workaround, I've continued with my scripting and code optimization, etc.

Just for the hell of it, I went back to the original way by hiding the object within the parent script again.
It works !?!?!? Very strange indeed. You wouldn't belive how many times I tried to no avail before.I have also discovered that the order of placing commands in the script seems to be a factor. (I'm not referring to variables or values before they exist, to which you would obviously get an error).

Don't know which method to use or trust. Very curious.

Thanx again - Joe
Reply #4 Top
This has me a little bit intrigued, but only for a random non relevant reason. Would you send me a copy or example object that shows this occuring? Email is here on the right: http://skarnivorous.wincustomize.com/info.aspx?acid=387257

Posted via WinCustomize Browser/Stardock Central