erich.wanker Posted June 2, 2016 Posted June 2, 2016 Hy .. how can i subtract the value of the scrollbar in this code: procedure TMAINFRAME_WARTUNG.m1Click(Sender: TObject); var x:Integer; begin x:= (sender as TUniContainerPanel).Top+200; // to become a correct position relative to screen UniSession.AddJS(f1.JSName + '.animate({ duration: 400, to: { y:'+inttostr(x)+'}});'); UniSession.AddJS(s1.JSName + '.animate({ duration: 400, to: { y:'+inttostr(x+117)+'}});'); end; This code works fine since the scrollbar of uniscrollbox1 is at the top ... if i scroll down, the position of "animate" does not match (animate is absolut to screen coordinates) uniscrollbox1 is located in MAIN ... the content is TMAINFRAME_WARTUNG = class(TUniFrame) .. m1, f1 and s1 are UniContainerpanels... Hope, someone can help ThanX Erich Quote
Sherzod Posted June 3, 2016 Posted June 3, 2016 Hi Erich, Sorry, can you clarify your issue again ?! .. Best regards. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.