SAP R/3 форум ABAP консультантов
Russian ABAP Developer's Club

Home - FAQ - Search - Memberlist - Usergroups - Profile - Log in to check your private messages - Register - Log in - English
Blogs - Weblogs News

Web dynpro textedit text edit wrapping convert to workflow



 
Post new topic   Reply to topic    Russian ABAP Developer's Club Forum Index -> SAP Business Workflow
View previous topic :: View next topic  
Author Message
vga
Мастер
Мастер


Age: 70
Joined: 04 Oct 2007
Posts: 1218
Location: Санкт-Петербург

PostPosted: Mon Dec 01, 2008 5:34 pm    Post subject: Web dynpro textedit text edit wrapping convert to workflow Reply with quote

Web dynpro textedit text edit wrapping convert to ITF workflow notes

Code:
  DATA:
    node_request_reasons                TYPE REF TO if_wd_context_node,
    elem_request_reasons                TYPE REF TO if_wd_context_element,
    stru_request_reasons                TYPE wd_this->element_request_reasons,
    item_text_lines                     LIKE stru_request_reasons-text_line.

  DATA:
    x_container TYPE swcont,
    w_note_line TYPE string,
    i_note_table TYPE STANDARD TABLE OF zcas_workflow_notes,
    x_note_table TYPE zcas_workflow_notes,
    t_itf_text TYPE STANDARD TABLE OF tline,
    w_itf_text TYPE tline.

* set the request reasons
  node_request_reasons = wd_context->get_child_node( name = wd_this->wdctx_request_reasons ).
  elem_request_reasons = node_request_reasons->get_element(  ).

  elem_request_reasons->get_attribute(
    EXPORTING
      name =  `TEXT_LINE`
    IMPORTING
      value = item_text_lines ).

  CALL FUNCTION ‘CONVERT_STREAM_TO_ITF_TEXT’
    EXPORTING
      stream_lines = item_text_lines
      lf           = ‘X’
    TABLES
      itf_text     = t_itf_text.

  LOOP AT t_itf_text INTO w_itf_text.
    CLEAR:  x_note_table.
    WRITE: w_itf_text-tdline TO x_note_table.
    APPEND x_note_table TO i_note_table.
  ENDLOOP.

  CALL FUNCTION ‘SWC_TABLE_SET’
    EXPORTING
      element       = ‘REQUEST_REASONS’
    TABLES
      container     = t_container
      table         = i_note_table
    EXCEPTIONS
      type_conflict = 1
      OTHERS        = 2.

  IF sy-subrc <> 0.
  ENDIF.
Back to top
View user's profile Send private message Blog Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Russian ABAP Developer's Club Forum Index -> SAP Business Workflow All times are GMT + 4 Hours
Page 1 of 1

 
Jump to:  
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.