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; Quote 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? Quote 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 Quote 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!? Quote 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? Quote 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!? Quote 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 Quote 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. Quote 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? Quote 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. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted November 30, 2022 Share Posted November 30, 2022 Okay, no problem. 1 Quote Link to comment Share on other sites More sharing options...
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.