wkotze Posted May 14, 2020 Posted May 14, 2020 Hi guys, i want on session termination to display message particular to that session, and i've set the servermessages on creation of mainmodule, BUT this property is ignored and the servermodule servermessages is displayed instead Im I doing something wrong, or is this a known issue ? Quote
Sherzod Posted May 14, 2020 Posted May 14, 2020 4 hours ago, wkotze said: and i've set the servermessages on creation of mainmodule, BUT this property is ignored and the servermodule servermessages is displayed instead Hello, You should use UniMainModule.ServerMessages... Quote
wkotze Posted May 15, 2020 Author Posted May 15, 2020 I do use UniMainModule.ServerMessages, this is however ignored and Servermodule is used ServerModule.ServerMessages is used procedure TUniMainModule.UniGUIMainModuleCreate(Sender: TObject); var t : string; begin t :='<html><body><a href="[###url###]/'+ UserCode +'"><br>[###message###]<br>Restart application</a></body></html>'; ServerMessages.ExceptionTemplate.text := t; ServerMessages.terminatetemplate.text := t; ServerMessages.invalidsessiontemplate.text := t; end; Quote
Sherzod Posted May 15, 2020 Posted May 15, 2020 1 hour ago, wkotze said: I do use UniMainModule.ServerMessages, this is however ignored and Servermodule is used ServerModule.ServerMessages is used Please tell me what exactly is not working, and how should it be..? Quote
wkotze Posted May 16, 2020 Author Posted May 16, 2020 Hi Sherzod, on session terminate i want go the user a link to log back in with his url parameters if session started with http:/ip/?prodid=100, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=100" if session started with http:/ip/?prodid=200, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=200" if session started with http:/ip/?prodid=300, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=300" The maninmodule. servermessages is howver ingonred, and the servermodule.servermessages is displayed termmsg.dpr Quote
donlego Posted May 29, 2020 Posted May 29, 2020 On 5/16/2020 at 1:42 PM, wkotze said: Hi Sherzod, on session terminate i want go the user a link to log back in with his url parameters if session started with http:/ip/?prodid=100, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=100" if session started with http:/ip/?prodid=200, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=200" if session started with http:/ip/?prodid=300, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=300" The maninmodule. servermessages is howver ingonred, and the servermodule.servermessages is displayed termmsg.dpr i need the solution to ,for this case Quote
donlego Posted May 30, 2020 Posted May 30, 2020 (edited) On 5/21/2020 at 3:55 PM, wkotze said: any news on this hello i found the way just empty your ulr href like this replace server message on server module & mainmodule Edited May 30, 2020 by donlego Quote
Administrators Farshad Mohajeri Posted May 30, 2020 Administrators Posted May 30, 2020 On 5/16/2020 at 9:42 AM, wkotze said: Hi Sherzod, on session terminate i want go the user a link to log back in with his url parameters if session started with http:/ip/?prodid=100, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=100" if session started with http:/ip/?prodid=200, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=200" if session started with http:/ip/?prodid=300, on session terminate i watn to hoew messgae : "Terminated, click here to return to http:/ip/?prodid=300" The maninmodule. servermessages is howver ingonred, and the servermodule.servermessages is displayed termmsg.dpr It is the default behavior. Try this in either ServerModule or MainModule: <html> <body bgcolor="#dfe8f6"> <p style="text-align:center;color:#0000A0">[###message###]</p> <p style="text-align:center;color:#A05050">Terminated, click <a href="[###url###]">here</a> to return to application.</p> </body> </html> Quote
wkotze Posted June 6, 2020 Author Posted June 6, 2020 Farshad, only servermodule.servermessages gets called, maninmodule. servermessages inot test1.zip Quote
Sherzod Posted June 6, 2020 Posted June 6, 2020 23 minutes ago, wkotze said: only servermodule.servermessages gets called, maninmodule. servermessages inot Hello, Please can you clarify, what does not work? Quote
wkotze Posted June 6, 2020 Author Posted June 6, 2020 both servermodule.servermessages and maninmodule. servermessages is set BUT only servermodule. servermessages display on session termination I want maninmodule. servermessages to display NOT servermodule. servermessages Quote
Tokay Posted September 15, 2024 Posted September 15, 2024 Up. I encountered the same issue. I need to show different servermessages for different users depending on the language selected by the user. I try to change maninmodule.servermessages (InvalidSessionMessage, UnavailableErrMsg, 4 strings) but nothing was changed. When I've changed servermodule.servermessages messages was changed, but globally for all the users. But that's not what I need. How is possible to show different messages for different logged users? 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.