Get Current User within Lookups API

Discussions related to order tracking development with the ProForm module.

Moderator: Phil Barton

Mark McKenna

Re: Get Current User within Lookups API

Post by Mark McKenna »

As a point of clarification, the WindowsIdentity approach will certainly work if your users are configured to use Windows user authentication, which is the default setting for Select. If you are using custom logins, however, you would need to work through the SelectServer.AuthenticatedUserName property as prescribed, since that will identify who is logged into Select as opposed to who is logged in to Windows.

Regardless, I'm still concerned about the exception you were getting, as it may be a precursor to future problems. Generally, an editor window class would derive from SoftPro.Select.Shell.EditorPane, and you would also provide an editor factory class that derives from SoftPro.Select.Shell.EditorFactory to create your editor window and expose it to our system. The factory is registered through a SoftPro.Select.Shell.Registration.ProvideEditorFactory attribute on your package class. By doing so, both your editor window and editor factory would have access to our service provider via the protected GetService methods provided by each base class, and so the following would return a valid reference:

Code: Select all

Select.Client.SelectServer sps = GetService( typeof( Select.Client.SelectServer ) ) as Select.Client.SelectServer;
You may be doing something similar already but it just wasn't evident from your code snippet, which is why I asked if it was being "popped up". If you'd like, you may email (just) your package to us so that we can take a look at exactly how you're integrating - I think you have John Morris' email.
Post Reply