1 Reply Latest reply on Jan 31, 2014 8:39 AM by Francisco Amores

    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