picyka Posted November 30, 2022 Share Posted November 30, 2022 Is there a possibility to click on a label and get its left and top position? Note: procedure TMainForm.lbColorLayoutClick(Sender: TObject); begin with TUniFormCorLayout.Create(UniApplication) do begin try Left := Self.lbColorLayout.Left + Width; Top := Self.lbColorLayout.Top + lbColorLayout.Height + 28; ShowModal; finally Free; end; end; end; Link to comment Share on other sites More sharing options...
Sherzod Posted November 30, 2022 Share Posted November 30, 2022 Hello, What is the problem at the moment? Link to comment Share on other sites More sharing options...
picyka Posted November 30, 2022 Author Share Posted November 30, 2022 22 minutes ago, Sherzod said: Hello, What is the problem at the moment? I clicked on the color icon, it doesn't open where I want procedure TMainForm.lbColorLayoutClick(Sender: TObject); begin with TUniFormCorLayout.Create(UniApplication) do begin var lControllerUsuario := TControllerUsuario.Create(UniMainModule.GetClientApiApp,UniMainModule.UserInfo); try var lUsuario := lControllerUsuario.Find(UniMainModule.UserActive.Id); if UniMainModule.UserActive.MenuSuperior then begin Left := Self.lbColorLayout.Left + Width; Top := Self.lbColorLayout.Top + lbColorLayout.Height + 28; end else begin Left := Self.lbColorLayout.Left + Width; Top := Self.lbColorLayout.Top + lbColorLayout.Height; end; ShowForm(lControllerUsuario, lUsuario); finally Free; end; end; end; Form: Position = poDesigned Link to comment Share on other sites More sharing options...
Sherzod Posted November 30, 2022 Share Posted November 30, 2022 Because you are using a client side alignment!? Link to comment Share on other sites More sharing options...
picyka Posted November 30, 2022 Author Share Posted November 30, 2022 1 minute ago, Sherzod said: Because you are using a client side alignment!? AlingmentControl = uniAlignmentServer How should I do? Link to comment Share on other sites More sharing options...
Sherzod Posted November 30, 2022 Share Posted November 30, 2022 Do you have a simple testcase to check!? Link to comment Share on other sites More sharing options...
picyka Posted November 30, 2022 Author Share Posted November 30, 2022 8 minutes ago, Sherzod said: Do you have a simple testcase to check!? Test.zip Link to comment Share on other sites More sharing options...
picyka Posted November 30, 2022 Author Share Posted November 30, 2022 I think it's my fault, I must sum the width of the left side panel together. Link to comment Share on other sites More sharing options...
Sherzod Posted November 30, 2022 Share Posted November 30, 2022 17 minutes ago, picyka said: I think it's my fault, I must sum the width of the left side panel together. So, it works now? Link to comment Share on other sites More sharing options...
picyka Posted November 30, 2022 Author Share Posted November 30, 2022 1 minute ago, Sherzod said: Então, funciona agora? yes, sorry. Link to comment Share on other sites More sharing options...
Sherzod Posted November 30, 2022 Share Posted November 30, 2022 Okay, no problem. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now