Solved

Delphi form movement after printing

Posted on 1998-11-15
5
132 Views
Last Modified: 2010-04-04
I have a Delphi form that selects an operation and then prints a report. It works fine except that when it finishes printing, the whole form moves to the bottom of the screen with only about half of it showing. The form is set to be centered on the screen and that is what it does until after the printing is completed. I am using graphics on the report, but I am doing the same thing on other forms that work perfectly. Any idea what is happening and what to do to prevent it?
0
Comment
Question by:DeCordova
  • 3
  • 2
5 Comments
 
LVL 4

Expert Comment

by:dwwang
ID: 1346918
Are you sure there is no statements causing the form to move?
0
 

Author Comment

by:DeCordova
ID: 1346919
If there are, I sure can't find them. What kinds of statements would cause the form to move? This happens to forms where I have some extensive graphics plotting lines, etc. no bitmaps. Could this have anything to do with it? I'm using Delphi 3 Standard Edition, by the way.

0
 
LVL 4

Expert Comment

by:dwwang
ID: 1346920
Could there be any statements that you used to control the printer or something like that, but forgot to use WITH ... do statements, so they actually affect the form?
0
 

Author Comment

by:DeCordova
ID: 1346921
Although you didn't have an answer for my problem, you got me to thinking in a different way. Here's what I found: I was using a variable "Top" to define the top of graphics lines on the page and I didn't declare it. Somehow Delphi let me get away with that because there must be a declaration somewhere in Delphi. When I used a different name for the variable and declared it that solved the problem. Thanks for your help.

0
 
LVL 4

Accepted Solution

by:
dwwang earned 100 total points
ID: 1346922
So would you mind I have the answer? :)
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question