At 12:05 PM 1/21/2008, PAUL HAIS wrote:

However, it does not work the way I need. When I go through your instructions,
it works on the print out of the statements, but does not work when I execute
the statements. What am I doing wrong?

Paul,

If you can post the command (statements), it would help a lot to see what you
are trying to do.

Since you were able to get a print out of the code (statements) using the
suggestion provided earlier, now let's work on getting the same results when
executing the code for CrossTab output with indented left margin.

Without knowing the exact code, follow the examples below and see if you can
adapt the same technique in your specific scenario.

-- Example 01 (Typical Scenario):

   CONNECT RRBYW14
   SET LINES 0
   SET WIDTH 100
   OUTPUT PRINTER
   CROSSTAB SUM NetAmount=12 FOR EmpID BY TransDate FROM InvoiceHeader +
   WHERE CustID = 127  AND EmpID < 110
   OUTPUT SCREEN
   SET LINES 19
   SET WIDTH 79

-- Example 02 (Same output with indented left margin):

   CONNECT RRBYW14
   SET LINES 0
   SET WIDTH 100
   SET SELMARGIN 5
   OUTPUT PRINTER
   CROSSTAB SUM NetAmount=12 FOR EmpID BY TransDate FROM InvoiceHeader +
   WHERE CustID = 127  AND EmpID < 110
   OUTPUT SCREEN
   SET LINES 19
   SET WIDTH 79
   SET SELMARGIN 0

-- Example 03 (Same output with your favorite font and font size):

   CONNECT RRBYW14
   SET LINES 0
   SET WIDTH 100
   OUTPUT PRINTER FONTNAME COURIER FontSize 10
   CROSSTAB SUM NetAmount=12 FOR EmpID BY TransDate FROM InvoiceHeader +
   WHERE CustID = 127  AND EmpID < 110
   OUTPUT SCREEN
   SET LINES 19
   SET WIDTH 79

-- Example 04 (Same results as PDF using the built-in PDF feature):

   CONNECT RRBYW14
   SET LINES 0
   SET WIDTH 100
   OUTPUT CrossTabResult.PDF PDF
   CROSSTAB SUM NetAmount=12 FOR EmpID BY TransDate FROM InvoiceHeader +
   WHERE CustID = 127  AND EmpID < 110
   OUTPUT SCREEN
   SET LINES 19
   SET WIDTH 79
   LAUNCH CrossTabResult.PDF

-- Example 05 (Same results as HTML Application - HTA)
-- Adapted from Mike Byerley's concept of HTA samples

   CONNECT RRBYW14
   SET LINES 0
   SET WIDTH 100
   OUTPUT CrossTabResult.HTA
   WRITE '<HTML>'
   WRITE '<BODY>'
   WRITE '<PRE>'
   CROSSTAB SUM NetAmount=12 FOR EmpID BY TransDate FROM InvoiceHeader +
   WHERE CustID = 127  AND EmpID < 110
   WRITE '</PRE>'
   WRITE '</BODY>'
   WRITE '</HTML>'
   OUTPUT SCREEN
   SET LINES 19
   SET WIDTH 79
   LAUNCH CrossTabResult.HTA

-- Example 06 (Using the CrossTab Control in Reports):

   Designing Custom CrossTab reports in R:BASE 7.6 for Windows
   http://www.rbase.com/rbg76/reports/CustomCrossTabReports.pdf

I hope one of these examples gives you the desired results!

Very Best R:egards,

Razzak.


Reply via email to