Hi Folks
I am new to this forum and some what to rev (I have had a license for awhile but just started to use it).
Most of my issues I have been able to solve except one. I am using Rev Studio 2.9 on Windows Vista and have look far a low on how to set the possition of my application. I want it on top in the center I think I need to use screenLoc but I am not sure how.
Truth be told what I really want to do is animate it kind of like a drawer (Click on a hot spot and it pulls down), I can do it in delphi but would really like to know how to do it in Rev.
Thanks in advanced for the help, I'm sure its one of those it's right in front of your face things.
Windows location.
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
This won't do exactly what you want, but it will hopefully give you some idea of what you can do - this will set the location of the stack "almost" offscreen at top centre on preOpenStack, and then on openStack it will slide it down to the centre of the screen. If you look up "screenrect" and "working screenrect" and "screenloc" and "loc" then I'm sure you'll get a lot of clues as to how to deal with what you want.
Code: Select all
on preOpenStack
set the loc of this stack to item 1 of the screenloc, 0 - (the height of this stack / 2) + 20
--sets centred in the x direction
--sets offscreen at the top in y direction, with
--20 pixel margin
end preOpenStack
on openStack
local tLoc
repeat until item 2 of the loc of this stack is item 2 of the screenloc
put the loc of this stack into tLoc
add 1 to item 2 of tLoc
set the loc of this stack to tLoc
end repeat
end openStack