Stickybeak Posted November 22, 2010 Posted November 22, 2010 I am trying to use the top of one window to move the top of another window to the same spot. I set a global variable using Get(WindowTop) then call a script in the second window with a resize step and set the top field to "$$top" - it doesn't work..... Can one use global variables in the resize dialogue?
Matthew F Posted November 22, 2010 Posted November 22, 2010 When you call the script for the second window is it part of the same database or is it in a second file? Global variables can be passed from one script to another in a single database but not to a script in an external database. Otherwise a global variable should work fine to resize or move a window.
Stickybeak Posted November 22, 2010 Author Posted November 22, 2010 different file ok so why cant the resize look up a field in the original database ? thanks for the input
Rick Whitelaw Posted November 22, 2010 Posted November 22, 2010 Variables are not passed between files. However, you can pass a variable as a Script Parameter between files. RW
Stickybeak Posted November 22, 2010 Author Posted November 22, 2010 Im going to see what I can do with script parameters but in the meantime I accomplished what i wanted to copy and pasting from field in DB1 using scripts in DB2 and then picking up those pasted values in the resize dialogue - its pretty clumsy and I dont want to keep doing it for every file in the solution.
Matthew F Posted November 22, 2010 Posted November 22, 2010 ok so why cant the resize look up a field in the original database ? I'm not sure how you would do that. Get(WindowTop) only applies to the current window. Instead of using a global variable save the results of Get(WindowTop) to a global field in the external database. Then call the external script, open the new window and use the global field in a move/resize step.
bruceR Posted November 22, 2010 Posted November 22, 2010 (edited) different file ok so why cant the resize look up a field in the original database ? It can. And even more easily if it is a global field. Also note that you do not need to call a script in window 2. Scripts in window 1 can move the windows for file window 2. WMove.zip Edited November 22, 2010 by Guest
Stickybeak Posted November 22, 2010 Author Posted November 22, 2010 hmmmmmm-this is what I was trying to do - I will need to see where I was going wrong Thanks for the effort
Recommended Posts
This topic is 5114 days old. Please don't post here. Open a new topic instead.
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