The following function is used to convert a WBS string to normalize it such that all levels other then the first are two characters. For example,
C.1.2.4 is normalized to C.01.02.04, C.12.2 is normalized to C.12.02 and so on.
C.12.1.2.12.1.1.1.1P normalizes to C.12.01.02.12.01.01.01.01 The function is below. Any ideas on why this is happening? The only recent change is that we upgraded from A2K to A2003.
Function NormWBS(txt As String) As String
Dim ar() As String
Dim i As Integer
ar = Split(txt, “.”)
NormWBS = ar(0)
For i = 1 To UBound(ar)
NormWBS = NormWBS & “.” & Format(ar(i), “00”)
Next i
End Function
The following was added at 1430
Interesting that the below string ending in P doesn’t work but the one ending in Y does?
C.12.1.2.12.1.4.1.1Y Normalizes correctly to C.12.01.02.12.01.04.01.1Y, but
C.12.1.2.12.1.4.1.1P normalized incorrectly to C.12.01.02.12.01.04.01.01
The following was added at 1441
1P in any part of the string converts to 01 however P1 converts correctly to P1. Interesting. It appears that only 1P fails as 1W, 1X, 1Y, all work properly. Im stumped.