Skip to Content

Error Batch Input using Office 2007 cvs

Hi guys.

I have a batch input that it is working fine with a file data .cvs using Office 2003. There was not problem until the PC was update and got Office 2007. It suppost that the CVS didnt change to CVSX, but everytime that i run the BI doesnt get data. If I use another PC with Office 2003, with the same file, the BI runs well.

The program use this sentence to upload the file.

CALL FUNCTION 'WS_UPLOAD'
    EXPORTING
      FILENAME                = PC_ARCH
      FILETYPE                = 'ASC'
    TABLES
      DATA_TAB                = TH_REC
    EXCEPTIONS
      CONVERSION_ERROR        = 1
      FILE_OPEN_ERROR         = 2
      FILE_READ_ERROR         = 3
      INVALID_TABLE_WIDTH     = 4
      INVALID_TYPE            = 5
      NO_BATCH                = 6
      UNKNOWN_ERROR           = 7
      GUI_REFUSE_FILETRANSFER = 8
      OTHERS                  = 9.

  LOOP AT TH_REC.
    SPLIT TH_REC-LINEA AT ';' INTO
     TH_ARCHIVO-zcliente_rec
     TH_ARCHIVO-zcliente
....

Any ideas why using Office 2007 the programs doesnt run well.???

Regards

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Dec 07, 2011 at 01:53 PM

    i did the exact same thing you did and its working fine in 2007. but you try saving the file in just .CSV not .CSVX.

    1 more thing, WS_UPLOAD is old... just use CL_GUI_FRONTEND_SERVICES class methods

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi, but i think that csvx doesnt exit on Office 2007, so it is just csv.

      In addition, the file is created using Office 2003 (.csv), then the user send it to another pc with Office 2007. The guy get the file open it to see if structure is OK, then without save it, runs the BI and the data doesnt get update it.

      If the user doesnt open the file pass very good.

      So, i guess that the office 2007 changes sth in the File, the extension or the format...no clue.

      Thanks

  • author's profile photo Former Member
    Former Member
    Posted on Dec 07, 2011 at 02:07 PM

    more over, it should be split by COMMA ",".. right?

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 08, 2011 at 01:55 PM

    Hi Miguel,

    this sounds as if it were a Unicode problem. Never use WS_UPLOAD, but CL_GUI_FRONTEND_SERVICES->GUI_UPLOAD.

    Best wishes

    Alexander

    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.