cancel
Showing results for 
Search instead for 
Did you mean: 

KW External Data Set with VB Script - Username to Keyword

Alvaro_Alarcon
Confirmed Champ
Confirmed Champ

I have a keyword setup with an external dataset that uses a VB Script to get the list.  To test it out i was trying to take the current users loginid to populate the list.  It worked when i first tested it but now i cant figure out what setting was changed or what happened but i come up with no results.

Hard coding the UserID variable gets me desired result but i want this to be dynamic depending on the user.

You may be asking why i don't handle something this simple another way, this is just a POC for me.  I have another script that makes a call to an external DB which works perfectly, I need the username to filter on it.

I am on Onbase 12 and this is going to run in a Unity client.  Any ideas as to what may have caused this to stop working?

Dim UserID

Function Main(objSession, objDocument)
     Set UserID = User.Name
     Call GetKeywordDataSetRecords(filterValue, context, result)
End Function

Sub GetKeywordDataSetRecords(filterValue, context, result)

    call result.BeginRow()
    call result.AddData("keyvaluechar", UserID)
   call result.EndRow()

End Sub

Thank you all in advance.

0 REPLIES 0