Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: UserSession Access Violation


This question is answered. Helpful answers available: 0. Correct answers available: 1.


Permlink Replies: 3 - Last Post: Jul 27, 2016 7:21 AM Last Post By: Peter Tickler
Peter Tickler

Posts: 15
Registered: 1/3/10
UserSession Access Violation  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 27, 2016 2:00 AM
Converting systems from Delphi2006 to RAD Studio Berlin, I have got them to compile, but I keep getting access violations which I have traced to UserSession unit. It doesn't see to have been created when the user logs onto ISAPI application. Is the userSession not created automatically, and if not how do I fix it so that it is created automatically?
Daniel Fields

Posts: 622
Registered: 11/29/04
Re: UserSession Access Violation
Helpful
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 27, 2016 2:25 AM   in response to: Peter Tickler in response to: Peter Tickler
It is supposed to get created automatically. The events and properties of the ServerController have changed, like assigning the MainForm. Maybe it does not exist somewhere there when you are attempting to access it. It really always exists in TIWUserSession(WebApplication.Data).

You might also want to try it as a Stand Alone to see if it is an ISAPI issue only.
Alexandre Machado

Posts: 1,754
Registered: 8/10/13
Re: UserSession Access Violation
Helpful
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 27, 2016 2:50 AM   in response to: Peter Tickler in response to: Peter Tickler
Peter Tickler wrote:
Converting systems from Delphi2006 to RAD Studio Berlin, I have got them to compile, but I keep getting access violations which I have traced to UserSession unit. It doesn't see to have been created when the user logs onto ISAPI application. Is the userSession not created automatically, and if not how do I fix it so that it is created automatically?

Yes they are supposed to be created automatically. If they are not, something is missing in your source code.

Have a look at this:

http://docs.atozed.com/docs.dll/development/Migrating%20to%20IntraWeb%20XIV.html#OnNewSession
Peter Tickler

Posts: 15
Registered: 1/3/10
Re: UserSession Access Violation  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 27, 2016 7:21 AM   in response to: Alexandre Machado in response to: Alexandre Machado
Thanks, I have got over that hurdle now. I amended the Servercontroller code and then made sure the OnNewSession event was calling it.
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02