Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ODBC Field for Crystal Reports Invoice Printing Line Message 1 and 2

Status
Not open for further replies.

alistek

IS-IT--Management
Jul 25, 2007
3
US
Hi,

I am creating a custom Crystal Report for printing Invoices and Sales Orders in the Sales Orders module. I managed to get the correct ODBC field for the Line Message 1 and 2 text fields in printing a Sales Order (ARK_InvStmntMsgMaster.StdMessageLine1 and ARK_InvStmntMsgMaster.StdMsgLn2HistInvcPrntMsgLn1) but I cannot find the correct field for printing an Invoice. If anyone knows what that field might be I would greatly appreciate. Thanks!

-Adam
 
What version of MAS is this? The fields should already be part of the tables. Are you modifying a existing form? Are you creating a form from scratch and if so what tables are you using.
 
Hi,

I am using version 4.05. I am sure that the fields are already part of the table but I don't know what fields to use and in what table. This is an Invoice form that was previously created in Crystal Reports and I am modifying it. The equation I am using is:

StringVar string1;
NumberVar number1;
NumberVar discount;

string1 := ToText ({AR_20CrystalStmntPrinting.StdMessageLine1});

IF (InStr (string1,"%") - 1) < 1.
THEN number1 := 1
ELSE number1 := (InStr (string1,"%") - 1);

IF IsNumeric (Mid (string1, number1, 1))
THEN discount := ToNumber (Mid (string1, number1, 1))
ELSE discount := 0;

IF discount = 0
THEN " "
ELSE ToText ({?Pm-@Net Invoice} * (discount * 0.01));

I am passing the Line Message 1 text value to a subreport via a parameter to calculate the discount amount since I cannot do multiple discount amounts on total orders so I am breaking it out on the Sales Order and the Sales Order Invoice. This equation works on the Sales Order form but when I enter a value into the same Crystal Report Invoice printing Line Message 1 text field it will not show up on the Invoice. Thanks!!

-Adam
 
This is because there are various types of forms being printed and you have to use the field that applies to that form. See below:

Order Printing Message Line 1 StdMessageLine1 String (1,50)
Order Printing Message Line 2 StdMsgLn2HistInvcPrntMsgLn1 String (51,50)
Invoice Printing Message Line 1 Ovr30DayLn1HistInvPrntMsgLn2 String (101,50)
Invoice Printing Message Line 2 Ovr30DayMsgLn2InvcPrntMsgLn2 String (151,50)
Picking Sheet Message Line 1 Over60DayPickSheetMsgLine1 String (201,50)
Picking Sheet Message Line 2 Over60DayPickSheetMsgLine2 String (251,50)
Packing List Message Line 1 PackingListMessageLine1 String (301,50)
Packing List Message Line 2 PackingListMessageLine2 String (351,50)
 
Thank you BigLouie that was very helpful, I was running into problems with gathering the correct data, helps to be in the right company but I wouldn't have known what field so thank you very much!!! Thanks again.

-Adam
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top