IlliaFM Posted April 26 Share Posted April 26 Hi all, I'm trying to use the above mentioned functions to hide/show my search bar when switching between certain panels, but the functions don't return what they are supposed to. I attached a script to OnPanelSwitch that flips a hide variable between 0 and 1, which works, but Get functions just show 0 in my Data Viewer. What could I be missing? Thanks. Link to comment Share on other sites More sharing options...
comment Posted April 26 Share Posted April 26 Without knowing exactly what you did, we can only guess. I don't like guessing. Take apart the attached demo file and see if you can spot what's missing in yours. OnPanelSwitch.fmp12 1 Link to comment Share on other sites More sharing options...
IlliaFM Posted April 29 Author Share Posted April 29 So the Get functions do work. I overlooked the fact that they don't retain the returned values after a panel has switched, which is why I saw no change in the Data Viewer. @comment I modified your demo file to replicate what I was trying to achieve with the search field. It's supposed to hide when you're on some panels and show when on others. It works, but only if you refresh the object or the whole window. Interesting why Hide/Show needs a refresh to work in this case. OnPanelSwitch_Modified.fmp12 Link to comment Share on other sites More sharing options...
comment Posted April 29 Share Posted April 29 1 hour ago, IlliaFM said: Interesting why Hide/Show needs a refresh to work in this case. Because Claris did not bother to add an "event listener" to monitor variables like they have with fields: OnPanelSwitch_Modified_Again.fmp12 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now