Johan

This really isn't going to be as easy as using ClientAction from the DataFlex side. The itemClick in this case takes (and requires) three arguments: tItem (not sure just what that would be, an object of some sort, but then pretty much everything in JavaScript is an object! <g>), fReturn (a function - functions are also objects in JavaScript! - which will be called if the event has not been cancelled) and an oEnv (the "environment" - scope - to call that function in). Your problem isn't just that oEnv is undefined - they all are!

You simply don't have access to those things in DataFlex, so can't pass them in ClientAction.

You might write some extra JavaScript to provide those and call that from DataFlex, but I think a better bet would be to either do it all in DataFlex, if that is possible, or, if you can or work out what fReturn is/does (use the browser's debugger to look), try calling that with ClientAction, although I'm guessing that wouldn't be simple either.

Have you tried just sending Show (in the DataFlex) to the object you want to switch to? That would seem the easiest approach.

Mike