后台运行程序,结果的输出宽度不够怎么办?

本文介绍了解决SP01中列表显示宽度总是被设置为255字符的问题,即使原始宽度不同。提供了针对不同SAP版本的解决方案,包括配置TSPOPTIONS表和使用SPAD交易。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

NOTES:186603有解决方案

Symptom
When you display a spool list in SP01 and when you process it further (for example, sending it to SAPoffice), the width of the list is always set to 255 regardless of how wide it was previously.

This means that the list can only then be edited with the format X_65_255.

Equally, the page length is normally not set so that only explicit page breaks result in a new page.

Other terms
Format, ABAP lists, SP01, 0000000040/spool()

Reason and Prerequisites
Because the actual width of the list is no longer known, the maximum width possible (255) is set so that no text is lost.
For the same reason the page length is not set.

Solution
1. Import all Support Packages mentioned below for your release.
2. Releases 4.6D and earlier: In Table TSPOPTIONS, use Transaction SE16 to create an entry with key REALWIDTH and value X.
Releases 4.6D and higher: Start Transaction SPAD and choose Settings->Spool System->Other. Select SP01: Number of Columns for List Display from Format.

The width of the list to be processed is read from the format used for creating the spool request. If this format is too narrow, the excessive characters are truncated.

3. Releases earlier than 4.6D: In Table TSPOPTIONS, use Transaction SE16 to create an entry with key REALHEIGHT and value X.
Releases >= 4.6D: Start Transaction SPAD and choose Settings->Spool System->Other. Select SP01: Number of Lines for List Display from Format.

The page length is read from the format used for creating the spool request.

4. As of Release 46C, after changing Table TSPOPTIONS, call Transaction SE37, and call the Function Module RSPO_OPTION_FLUSH with NAME=*, otherwise the changes will not take effect. Alternatively, change Table TSPOPTIONS directly using function module RSPO_OPTION_SET.

Caution: In Releases 4.6B and 4.6C, SP01 cannot display more than 255 columns of the list contents when displaying a spool list, even if the aforementioned Support Packages were installed. Due to internal restrictions, this is only possible in Release 4.6D and after.


Example: In Release 4.6B/4.6C, a spool request with 300 columns and format Y_65_300 is created. If a suitable device type supporting the customer-specific format Y_65_300 is used, this request can be printed correctly provided that the 4.6D kernel is installed. With the Support Packages mentioned below and entry "REALWIDTH" in TSPOPTIONS, the actual list width of 300 is set when displaying the spool request in SP01 but the list contents is displayed until column 255 only.


As a workaround for customers who urgently need a display option for wide lists in Releases 4.6B or 4.6C, the ABAP source code for report ZRSPOSHOWLIST is available as an attachment to this note. This report requests entry of a spool request number and then displays the spool list in full width.


CAUTION: If you are using the updated SP01 (or report ZRSPOSHOWLIST) and have created a suitable "wide" spool format for your device type (for example Z_65_375) with which the spool request is created, but you still see "cut-off" lines in SP01 or ZRSPOSHOWLIST display, check the following:
a) What is the actual maximum number of columns written into the spool request by the application program?
b) Does this actual maximum column width exceed the column count I set for the print format?
A simple method to count the columns of a spool list is to display the list using SP01/ZRSPOSHOWLIST and download this (unconverted) into a *.txt file. Now open this file with Windows Notepad, choose a non-proportionally spaced font (for example Courier New) and count the columns in the list.


See also the Support Packages contained in Note 521978.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值