Forum > Beginners

Improving custom message box

<< < (2/3) > >>

wp:

--- Quote from: pascal111 on June 30, 2022, 12:42:08 pm ---
--- Quote ---Please attach images to your forum posts instead of some third-party cloud sites which will be gone at some time in the future.

--- End quote ---
I tried some other ways and failed maybe due our internet here in my area in Egypt. This is the best site I have. If you know better way, tell me.

--- End quote ---
I meant: If you want to attach an image to your forum post, click on "Attachments and other options" below the forum's edit box, and specify the name of the file to be attached in the "Attach" box. But note that the max upload size is 500 KB only which you can easily exceed with images. Always use a compressed format such as .jpg or .png. You can also add projects this way: Add the .pas, .lfm, .lpr and .lpi files to a common .zip which you can upload this way. Do not add the other files, and particularly not the binary because this will exceed the upload limit (and we don't need them anyway because we want to compile the project and see the issues ourselves).

pascal111:

--- Quote ---I meant: If you want to attach an image to your forum post, click on "Attachments and other options" below the forum's edit box, and specify the name of the file to be attached in the "Attach" box. But note that the max upload size is 500 KB only which you can easily exceed with images. Always use a compressed format such as .jpg or .png. You can also add projects this way: Add the .pas, .lfm, .lpr and .lpi files to a common .zip which you can upload this way. Do not add the other files, and particularly not the binary because this will exceed the upload limit (and we don't need them anyway because we want to compile the project and see the issues ourselves).

--- End quote ---

I think you mentioned "500 KB"! is it per each time? I think that.

I modified my new unit "helper1" with code you provided me:

https://github.com/pascal111-fra/Lazarus-programs/blob/main/helper1.pas

wp:
Did you see my comments that I added to the Top/Left calculation? I think other_form.Width and other_form.Height must be exchanged. And why "div 3" in one case, and "div 2" in the other?

pascal111:

--- Quote from: wp on June 30, 2022, 06:08:53 pm ---Did you see my comments that I added to the Top/Left calculation? I think other_form.Width and other_form.Height must be exchanged. And why "div 3" in one case, and "div 2" in the other?

--- End quote ---

I didn't notice that. Ok! I'll fix it.

pascal111:
I fixed it, and why "div 2" now, because I'm searching for any proper ratio that places the message box close to the center of its calling form.

https://github.com/pascal111-fra/Lazarus-programs/blob/main/helper1.pas

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version