get userdata from a element

I have created this routin.

Dim oElement As Element
Dim ElemId As DLong
Dim Id As String
Dim Regel As String
Dim oEnumerator As ElementEnumerator
Dim oScanCriteria As New ElementScanCriteria
 
oScanCriteria.ExcludeAllTypes
oScanCriteria.IncludeType msdElementTypeLine
oScanCriteria.IncludeType msdElementTypeArc
'oScanCriteria.IncludeType msdElementTypeText
'oScanCriteria.ExcludeAllColors
'oScanCriteria.IncludeColor 0
counter = 0
counter2 = 0
counter3 = 0
Open "H:/temp/element.txt" For Output As #1
Set oEnumerator = ActiveModelReference.Scan(oScanCriteria)
Do While oEnumerator.MoveNext
Set oElement = oEnumerator.Current
If oElement.Type = msdElementTypeLine Then
counter2 = counter2 + 1
ElemId = oElement.Id
'Regel = oElement.GetExtractlinkage
Id = DLongToString(ElemId)
Print #1, Id & regel
ElseIf oElement.Type = msdElementTypeArc Then
counter = counter + 1
End If
counter3 = counter3 + 1
Loop
Close #1
MsgBox "The total number of elements scanned were: " & CStr(counter3) & ":" & CStr(counter2) & ":" & CStr(counter)
End Sub 

 now i want to get som user data from a element. when i use microstation basic the commant for it is:

Function locate_isElementAcceptable (elem as MbeElement,regel as String) as Integer
  regel$=space$(80)
  If elem.type = MBE_Text or elem.type = MBE_LineString or _
     elem.type = MBE_Line or elem.type = MBE_Arc or _
     elem.type = 2 or elem.type=15 Then
     status=elem.extractLinkage(regel, 19276)
    If status <> Mbe_Success Then exit function
  Else 
    regel="GEEN FUNCTIE"
'        MbeSendKeyin "beep"
    exit function
  End If
  locate_isElementAcceptable = TRUE
End Function
 

but this is not working in VBA. i want to get this "status=elem.extractLinkage" working in my routin