?

Log in

iCamel
Разрозненные обрывки
зачем я это сделал? 
17th-May-2016 05:07 pm
БА
Public Function parseUC(aRange As Range) As String

    parseUC = ""
    
    ucArray = Split(aRange.Cells(1, 1).Formula, ",", -1, vbTextCompare)
    
    On Error Resume Next
    
    For Each uc In ucArray        

        ucName = WorksheetFunction.Lookup(Trim(uc), Range("ucreference[Use Case]"), Range("ucreference[Description]"))
        
        If ucName = "" Then ucName = "N/F"
        
        parseUC = parseUC & ucName & "," & Chr(10)
    
    Next uc
    
    parseUC = Left(parseUC, Len(parseUC) - 2)

End Function
Public Function parseUC(aRange As Range) As String

    parseUC = ""
    
    ucArray = Split(aRange.Cells(1, 1).Formula, ",", -1, vbTextCompare)
    
    lastUCname = ""
    lastUC = ""
    
    On Error Resume Next
    
    For Each UC In ucArray
        
        ucName = WorksheetFunction.Lookup(Trim(UC), Range("ucreference[Use Case]"), Range("ucreference[Description]"))
        
        If ucName = lastUCname And lastUC <> UC Then ucName = "N/F"
        
        parseUC = parseUC & ucName & "," & Chr(10)
        
        lastUCname = ucName
        lastUC = UC
    
    Next UC
    
    parseUC = Left(parseUC, Len(parseUC) - 2)
    
    On Error GoTo 0
    
 End Function
Все равно. Зачем?
This page was loaded Feb 27th 2017, 8:43 pm GMT.