Jump to content

Identify WebMode and Link


Guest
 Share

Recommended Posts

Message from: "Cezar Wagenheimer"

 

?How to Identify If my session is in Desktop Mode or Web Mode?

 

In WebMode, how to get the current library link? I want to retrieve the

current link, something like 'http://unigui.wagenheimer.com:8077/', is this

possible?

 

Thanks!

 

.

 

Link to comment
Share on other sites

Message from: "ldb"

 

Il 22/12/2010 14:50, Cezar Wagenheimer ha scritto:

> ?How to Identify If my session is in Desktop Mode or Web Mode?

>

> In WebMode, how to get the current library link? I want to retrieve the

> current link, something like 'http://unigui.wagenheimer.com:8077/', is

> this possible?

>

> Thanks!

 

 

"Harry Rogers" wrote in message

news:gDb0uZccLHA.512@anaxagvs227...

> > Hi Farshad

> >

> > Which property should be checked to tell if an instance of an app is

> > the desktop/VCL or a browser ?

> >

Inside a UniForm instance you have public property "WebMode".

In other places "UniWebMode" global variable (defined in UniGUIRTTI unit)

can be used.

 

 

 

.

 

Link to comment
Share on other sites

Message from: "Farshad Mohajeri"

 

"Cezar Wagenheimer" wrote in message

news:sL3ks8doLHA.2084@anaxagvs227...

> ?How to Identify If my session is in Desktop Mode or Web Mode?

>

 

You can check boolean var WebMode inside a Form or global UniWebMode

wherever else.

 

> In WebMode, how to get the current library link? I want to retrieve the

> current link, something like 'http://unigui.wagenheimer.com:8077/', is

> this possible?

>

 

UniLabel1.Caption:=UniApplication.UniSession.Host;

 

 

 

.

 

Link to comment
Share on other sites

  • 2 weeks later...

Message from: "Farshad Mohajeri"

 

"Junior/RO" wrote in message

news:ioevgjSrLHA.2316@anaxagvs227...

> Farshad Mohajeri escreveu:

>

>> UniLabel1.Caption:=UniApplication.UniSession.Host;

>

> I have a similar issue.

>

> Can I use global UniSession to know the host?

 

yes, but global UniSession is not defined outside of event scope. i.e. you

can't use it in a thread which runs independant of framework core.

 

 

.

 

Link to comment
Share on other sites

Message from: "Junior/RO"

 

Farshad Mohajeri escreveu:

 

> yes, but global UniSession is not defined outside of event scope. i.e. you can't use it in a thread which runs independant of framework core.

 

I have asked you about the global UniSession because seems that 'TUniMainModule.UniApplication' property is declared as of type TComponent and I can't access the UniSession property.

 

Inside of a TUniForm, the UniApplication that I can access is a TUniGuiApplication and give me the UniSession property.

.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...