mierlp Posted January 30, 2013 Posted January 30, 2013 Hi, I load some values for the serverModule from a .ini file...so also SesstionRestrict with this code (nothing fancy) UniServerModule.ServerLimits.SessionRestrict:=Inifile.ReadString('SERVER', 'SessionRestrict', 'srNone'); i got the following compile error: [DCC Error] MainModule.pas(91): E2010 Incompatible types: 'TUniSessionRestrict' and 'string' Also when i first assign the value to a variabel (let's say for the example TEST) i got the same error : UniServerModule.ServerLimits.SessionRestrict:=TEST; What type is the SessionRestrict value (not a string and integer) ? Regards Peter Quote
mierlp Posted February 3, 2013 Author Posted February 3, 2013 Noby any suggestion....? When i assign it by code like below in the UniGUIServerModuleBeforeInit it works..but i UniServerModule.ServerLimits.SessionRestrict:=srOnePerIP; When using it as a variabel it' doesn't work...and all other server settings which i assign by variable are working...the settings are readed from a config.ini. Settings which i change and working are : UniServerModule.Port UniServerModule.AllowMultiIP UniServerModule.LoadingMessage UniServerModule.ServerLimits.MaxConnections UniServerModule.ServerLimits.MaxSessions UniServerModule.ServerLimits.SessionRestrict UniServerModule.ServerMessages.InvalidSessionMessage UniServerModule.ServerMessages.TerminateMessage UniServerModule.SessionTimeOut UniServerModule.Title UniServerModule.UnavailableErrMsg regards Peter Quote
Administrators Farshad Mohajeri Posted February 4, 2013 Administrators Posted February 4, 2013 You must use typcastng Quote
Semper Posted August 7, 2013 Posted August 7, 2013 How to localize or modify the message Can not create more sessions? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.