[API]
GetFullPathNameA
GetFullPathNameW

[INCLUDE]
TemporaryMemory
PeekS

[CODE]
Public Function GetFullPathName(ByVal xChar1 As String) As String
  Dim xLong1 As Long
  
  If IsUnicode Then
    xLong1 = GetFullPathNameW(StrPtr(xChar1), ptrTempSizeXW, ptrTemp, 0&)
    Else
    xLong1 = GetFullPathNameA(xChar1, ptrTempSizeX, ptrTemp, 0&)
    End If
  If Not xLong1 = 0& And xLong1 < 256& Then
    GetFullPathName = PeekS(ptrTemp, xLong1)
    ElseIf Mid(xChar1, 2&, 2&) = ":\" Or Left(xChar1, 2&) = "\\" Then
    GetFullPathName = xChar1
    End If
  End Function
