ContextFactoryCreateBySessionToken Method |
Namespace: AskiaFieldCom
public static IContext CreateBySessionToken( IFieldConnection connection, string sessionToken )
Create a context using the session token
var moduleName = "AskiaPortal"; var connectionString = "Server=(local);Database=CcaTest;Trusted_Connection=yes"; var address = "localhost"; var port = 980; var connection = FieldConnectionFactory.Get(moduleName, connectionString, address, port); if (!connection.Success) throw connection.Exception; var sessionToken = "a-valid-token"; var context = ContextFactory.CreateBySessionToken(connection, sessionToken);