Posted: Thu Oct 22, 2009 4:28 pm Post subject: Не работает SOI метод insert_one_table в ECC 6.0
Здравствуйте!
Сделали апгрейд до ECC 6.0 и перестал работать метод insert_one_table класса I_OI_SPREADSHEET. Это относится к пакету SOFFICEINTEGRATION, вставка целой таблицы в Excel.
Насколько я помню, этот метод некорректно выгружает русский текст из-за проблем с кодировкой. Советую лучше воспользоваться методами insert_range или insert_full.
Пробовал вместо текстов выгружать в каждом поле '1', все равно не работает. Не образает, как писали на сапфоруме, а вообще ничего не выгружает. Но пример vga работает. Разбираюсь.
Вообщем раньше для построения таблицы с описанием полей FIELDS_TABLE использовалась функция RFC_GET_STRUCTURE_DEFINITION, заменил ее на DP_GET_FIELDS_FROM_TABLE, как в примере и все поехало. Вот дела.
А насчет образания русских символов из sap пришел ответ, но как оказалось проблема была не в этом.
Quote:
This is design limitation in SAPGui and Unicode system.
The only possible work around for this problem
when you are using insert_one_table is below:
WorkAround1: The length of the table field which will contain mutibyte
character(Cyrlic Russian, Japanese etc) should have atleast double
the length of maximum number of character that can be entered
in the field.
This is because SAPGui is in Multibyte mode where as R/3 release
(Backend) is unicode mode.
In multibyte system each character takes 1 to 5 bytes. Where as
in Unicode it is always 2 bytes. If any field in table contain
mulibyte character which will become more than 2 bytes in multibyte
system then this truncation occurs.
For Example:
If you have entered 20 cyrlic russian character then minimum length
should be 40 characters.
Workaround2:
In this it is necessary to change the coding and stretch it
programmatically.
Please use function call DP_STRETCH_TABLE to stretch the required field.
Please apply note 1336789 in which I showed how to use stretch table
in the program "SAPRDEMO_MAILMERGE_INTERFACE".
data parameter takes the table, while column_to_stretch is array string
which will take column names that has to be stretched.
With this we request you to change the length of the field in the table
which you are using with insert_one_table as explained above.
Since the issue is in basic design level of SAP it is not possible for
us to give any fix for this problem. After detail discussion about this
problem we concluded this and decided to give above mentioned workaround.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
All product names are trademarks of their respective companies. SAPNET.RU websites are in no way affiliated with SAP AG. SAP, SAP R/3, R/3 software, mySAP, ABAP, BAPI, xApps, SAP NetWeaver and any other are registered trademarks of SAP AG. Every effort is made to ensure content integrity. Use information on this site at your own risk.