1 Reply Latest reply: Jan 31, 2014 2:39 AM by Francisco Amores RSS

    Script changes for Multi Load

    927283


      Hi,

      I have a few Import format scripts which work fine when doing a single period load but they dont work for Multi loads. Can I just copy and paste the Functions into the Multi Load sub routine or the script needs to be changed. I copy pasted the following script into MultiLoadAction Sub and it gives me an error. Any help will be highly appreciated.

      Function GetActivity(strField, strRecord)
      iTotalNumberOfColumns = 9  'Total number of columns in load file
      iColumnE =5  'column number for Column E
      iColumnF =6  'column number for Column E
      iColumnG =7  'column number for Column G
      strFileDelimiter = ","  'File Delimiter
      strColumnE = DW.Utilities.fParseString(strRecord, iTotalNumberOfColumns, iColumnE, strFileDelimiter )
      strColumnF = DW.Utilities.fParseString(strRecord, iTotalNumberOfColumns, iColumnF, strFileDelimiter )
      strColumnG = DW.Utilities.fParseString(strRecord, iTotalNumberOfColumns, iColumnG, strFileDelimiter )


      If strColumnE = "None" Then
      GetActivity = strColumnG & strColumnE
      Elseif strColumnF = "603" Then
      GetActivity = strColumnG & strColumnE
      Elseif Left(strColumnG,1) = "8" Then
           GetActivity = strColumnG & strColumnE
      Else
           GetActivity = strColumnE
      End If
      End Function

        • 1. Re: Script changes for Multi Load
          Francisco Amores

          Hi,

           

          which Multi-load template are you using? Excel or Text?

           

          Import format is not processed when you use Excel Template. You can use Excel functions to produce data in the format you expect.

           

          Besides, you cannot just copy and paste your function in Multiload action script.

           

          Regards