I have create a Script Library in Java Language, not Java Agent.
In Java Agent, I can use
Session s = getSession()
to get current session
I use the following code to call Java in Script Library
Dim mySession As JavaSession
Dim myClass As JavaClass
Dim myObject As JavaObject
Set mySession = New JavaSession()
Set myClass = mySession.GetClass("JFrameTest")
Set myObject = myClass.CreateObject()
Since I do not know user's password and I don't want user to enter password
So, I can't use the following code
notessession = NotesFactory.createSession("","",password)
Is is possible to getsession directly In Java Script Library?
Finally, I found this post LS2J bridge and Notes Session in Russian.
I solved my problem. According to my understanding, this is an architectural limitation, but the author gave solution. Thanks to him.