NetTalk Central

Recent Posts

Pages: [1] 2 3 ... 10
1
Hi Ron,

Thanks for you reply.
Your suggestion has helped me sort out another problem in another part of the system I have been battling with.

Regards
Johan de Klerk
2
Hi Jane,

Your advice for SetHostValue and GetHostValue works perfect.
Thank you very much.

Regards
Johan de Klerk
3
Johan,
BTW, the procedures are STATELESS - that means that they do not stay open until closed.  The NT code keeps cycling through the procedure and keeps track of the stage it was in when NT engine last went though it.  So, the code keeps cycling through the form until the user closes it with some action.  SO, watch the stage in a trace as your app runs and you will see it cycling through stages.  There is even a check box on forms to write the stage to the trace.
Ron
4
Hi Johan,
Again, I ask the same question that Jane asked.  What are you trying to do?
I am doing some file upload and manipulation and then save.  The code runs several times but I only wanted it to run ONCE.   So, I looked at the stage number for the stuff I wanted to do and found that it would run only ONCE if I limited it to a certain stage - there are equates for the stage numbers in a form. So, looking at the stage number when your code fires might help you limit it to only a certain stage.
Ron
5
What are you trying to do, Johan?

A session value is going to be tied to a particular session ID, so it will only be "global" for that one session.

I use a number of regular global variables in web apps that are set at startup and then read-only thereafter.

If you don't want to use global variables, you can set host values in the web server procedure when it starts (maybe in ThisWindow.init).  (Since pweb does not exist in the web server, you would use s_web.SetHostValue).



6
Hi All,

by accident I discovered that sometimes in the Webserver procedure, the following code (generated in legacy in: "before closing window"), has the following order

      s_web.iSession.Save()
    ThisWebserver.Kill()                              ! Generated by NetTalk Extension

but sometimes these lines are generated like this:

    ThisWebserver.Kill()                              ! Generated by NetTalk Extension
      s_web.iSession.Save()

I really don't know wether this is a problem or not (I didn't notice anything weird ...), but I think that for legacy this is cause by the following template code snippets that use the same priority() (see "nettalk.tpl"):

#AT(%BeforeWindowClosing),Priority(4500)
  #If((%NoNetTalk=0) and (%NoThisObj=0) and (%Family='cw20'))
%ThisObjectName.Kill()                      ! Generated by NetTalk Extension
  #EndIf
#ENDAT

#AT(%BeforeWindowClosing),Priority(4500)
  #If(%NoNetTalk=0 and %NoThisObj=0 and (%ABCBaseClass='NetWebServer' or sub(%ABCBaseClass,1,13)='NetWebServer_') and %Family='cw20')
    #IF(%FirstWebServer=%ActiveTemplateInstance)
#Insert(%ServerStateKillStuff)
    #endIf
  #EndIf
#ENDAT

Regards,
Ton
7
Hi,

I need to set some p_web.SSV('xx',YY) variables when the Web Server starts.
It must/need run this once and not on any subsequent requests.

The p_web.GSV('xx') will be used in various browses and forms.
It will be treated as some global variables.

I looked and put a lot or Trace statements in various embeds but all of them runs every time some fields, buttons, option or variable is clicked.

Any help would be appreciated.

Regards

Johan de Klerk
8
Web Server - Ask For Help / Re: netwebclient : IPv6 addresses and port
« Last post by AtoB on August 19, 2026, 11:46:45 PM »
Hi Bruce,

hmm ...

I tried the brackets around het ::1 part, but then the "server" becomes "[" (which is expected with current Stringtheory code as far as I can tell as there is no code that accounts for the brackets per se and it looks for the ":" from left to right).

Both "::1:port" and "[::1]:port" don't seem to work.

I've attached a screenshot of some debugview (in yellow the original request and the server part netwebclient resolves to)

Am I missing something still?

Regards,
Ton
9
Web Server - Ask For Help / Re: NT CLient for updating DDNS for DNSSIMPLE
« Last post by Jane on August 16, 2026, 08:09:11 PM »
Ron,
After you get it working in CURL, you can also do some testing with the web client that's in the NetDemo app in the NetTalk examples.
It's useful because you can see what's sent and received and figure out how to make things work.
10
Web Server - Ask For Help / Re: NT CLient for updating DDNS for DNSSIMPLE
« Last post by rjolda on August 16, 2026, 03:11:24 PM »
HI Bruce,
This is new to me as I rely on Net Talk products to do the work for me!  I did not know that I could run curl from command line.  That is a great way to test the login authorization.  Will give it a go. Thanks for the info.
Ron
Pages: [1] 2 3 ... 10