Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Unicode Issue

Kinsbrunner
Active Contributor
435

Hi all!

I'm updating from a non-Unicode system to a Unicode one and I'm getting the following error on both Translate statements:

"HEX00" must be a character-type data object (data type C, N, D, T or STRING)."

"HEXFF" must be a character-type data object (data type C, N, D, T or STRING)."

The code is the following:

+

DATA: BEGIN OF HEX00,

A(1) VALUE ' ',

C(1) TYPE X VALUE '20',

END OF HEX00.

DATA: BEGIN OF HEXFF,

A(1) VALUE ' ',

C(1) TYPE X VALUE 'FF',

END OF HEXFF.

RANGES: R_OBJECT FOR STXH-TDOBJECT.

TRANSLATE R_OBJECT-LOW USING HEX00.

TRANSLATE R_OBJECT-HIGH USING HEXFF.

+

Please I need a solutino as soon as possible.

Regards,

Alejandro.

Edited by: Alvaro Tejada Galindo on Feb 7, 2008 6:12 PM

2 REPLIES 2
Read only

Former Member
391

Try this, I'm not sure if it will help


data: hex20var(2), hexffvar(2).

concatenate hex00-a hex00-c to hex20var.
concatenate hexff-a hexff-c to hexffvar.

and do


TRANSLATE R_OBJECT-LOW USING HEX20var.
TRANSLATE R_OBJECT-HIGH USING HEXFFvar.

Read only

Former Member
391

Hi,

check this link

http://help.sap.com/saphelp_nw2004s/helpdata/en/79/c55458b3dc11d5993800508b6b8b11/content.htm

try this way,

DATA: BEGIN OF HEX00,

A(1) VALUE ' ',

C(2 TYPE CVALUE '20', "Change data type for X to C

END OF HEX00.

DATA: BEGIN OF HEXFF,

A(1) VALUE ' ',

C(2 TYPE CVALUE 'FF', "Change data type for X to C

END OF HEXFF.

Regards,

Ali