Solved

Crystal reports alignment problem

Posted on 2001-08-12
5
941 Views
Last Modified: 2012-06-22
I have a crystal report that is printed on a matrix printer declared as a generic text only printer (very important). If i print it from a visual basic program, the character fields are printed in the next row, after the numeric fields even if they should appear in the same row (they all are aligned top and have same height)
If i print the report from the crystal reports designer everything is ok. Can anyone help me with this?

Thank you
0
Comment
Question by:Barnabas3
  • 2
  • 2
5 Comments
 
LVL 12

Expert Comment

by:DRRYAN3
ID: 6377234
CrystalDecisions recommends using Courier New or Times New Roman in these type of reports.  There is a document available which explains the printer dependencies:
http://www.crystaldecisions.com/docs  - enter SCRPrinterDependency.pdf as the document name to find.

The problem you are seeing is common when exporting to text files and occurs when the fields are not lined up horizontally.  You might try lining your fields up using the Bottom alignment instead of Top.  Make sure that Generic/Text Only is set as your default printer while you are in the Designer.
0
 
LVL 12

Expert Comment

by:DRRYAN3
ID: 6377680
Another thought - are you using the horizontal guidelines and snapping the bottom of your fields to these guidelines?
0
 
LVL 9

Accepted Solution

by:
Valliappan AN earned 200 total points
ID: 6379117
1) Check your default printer if it is Generic Printer. To our experience, CR, prints well for default printers, and not so, for other printers, when we change CR's printer from VB, for landscape reports.

2) Also check if the line height is equal to atlease 2 grid point spaces. I would try to explain this like, Say each dot represent a grid dot.

.
.
.

Your character/character space height normally, could be a minimum of this height. This one, you could align using 2 guidelines, one at the top and one at the bottom.

3) Check the page size to which you are printing. If the page size is smaller, then you could get this word wrap.

4) If the field width that you have specified in CR is smaller, for particular larger width data, then, the line wraps also.

Cheers
0
 

Author Comment

by:Barnabas3
ID: 6386054
I solved my problem: i don't use the report's preview, i set the Destination property to crptToPrinter instead of crptToWindow. I realized that after a succesfully print from the designer, from the print button. Anyway valli's observation is very corect regarding the default printer. Unfortunatelly i cannot set the generic printer to be the default one.
Thank you both for the comments.
0
 
LVL 9

Expert Comment

by:Valliappan AN
ID: 6397927
Barnabas3, if need be, you could set the Generic printer as default temporarily and print to it and then set back the orig. default printer, for which if need be, i can help u.

It is just a class module to do this, once you release the object, the orig.defa. printer will be set.

cheers
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

932 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now