Skip to Content
author's profile photo Former Member
Former Member

Assigning a data object to a structure

Hi All,

I am working on Upgrading 4.6C to ECC 6.0, Here iam facing a problem with Assignment Operation, I will describe the problem here.

data: var(2000) type c.

and I have Structure also declared let us say that -- struct.

now the assignment is like this.

struct = var.

Can any one solve my problem

Thansk in Advance.

Srikanth.N

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    Posted on Jul 02, 2007 at 07:37 AM

    Hello Srikanth

    SAP provides us with a standard class (<b>CL_ABAP_CONTAINER_UTILITIES</b>) to solve this assignment problem under <i>Unicode </i>once and forever.

    In your case you want to read a C-container (string or C-like field) into a corresponding structure. Thus, use method <b>CL_ABAP_CONTAINER_UTILITIES=>READ_CONTAINER_C</b>.

    For the reverse operation, i.e. assigning a structure to a C-container, use method READ_CONTAINER_C=>FILL_CONTAINER_C.

    Regards

    Uwe

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jul 02, 2007 at 07:03 AM

    Hi

    be clear with the requirement?

    What data does the structure contains? and what data you store in the Var(2000) field?

    generally we split the var(2000) data into the Different fields of the structure and use

    Here you says simply assigning? what for? what's the data in both?

    Reward points for useful Answers

    Regards

    Anji

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.