[Gambas-user] WebForm

Jussi Lahtinen jussi.lahtinen at gmail.com
Sun Apr 11 20:12:56 CEST 2021


It seems that the pointer to public variable changes without clear reason.

Jussi

On Sun, Apr 11, 2021 at 9:10 PM Jussi Lahtinen <jussi.lahtinen at gmail.com>
wrote:

>
> Benoit, are there some limitations regarding public variables (I couldn't
> find any documentation about it) or is this a bug?
>
>
> Jussi
>
> ---------- Forwarded message ---------
> From: Mike Crean <mike.crean at y7mail.com>
> Date: Sun, Apr 11, 2021 at 7:06 AM
> Subject: Re: [Gambas-user] WebForm
> To: Jussi Lahtinen <jussi.lahtinen at gmail.com>
> Cc: Gambas Mailing List <user at lists.gambas-basic.org>
>
>
> Attached example app. on Gambas 3.15.2
>
> Regards
> Mike
>
>
>
>
>
> On Sunday, 11 April 2021, 11:07:59 am AWST, Jussi Lahtinen <
> jussi.lahtinen at gmail.com> wrote:
>
>
> Please send a runnable project.
>
> Jussi
>
> On Sun, Apr 11, 2021 at 5:17 AM Mike Crean <mike.crean at y7mail.com> wrote:
>
> OK in version 3.15.2 the timer is set to true. My problem is how do I make
> an Integer public to all functions in a WebForm class.
> Cnt will not continue to increment each time the timer fires. The code
> below is taken from opening a new Web form application and modifying the
> example code.
>
> Eg.
>
> ' Gambas class file
>
> Export
> Public Cnt As Integer
>
> Public Sub WebForm_Open()
>  WebTimer1_Timer
> End
>
> Public Sub WebTimer1_Timer()
>   WebLabel1.Text = Format(Now, "hh:nn:ss")
>   Inc Cnt
>   Cnt = Cnt + 1
>   WebLabel2.Text = Cnt
> End
>
> Regards
> Mike
>
>
>
>
>
> On Sunday, 11 April 2021, 2:59:35 am AWST, Jussi Lahtinen <
> jussi.lahtinen at gmail.com> wrote:
>
>
> Can you send the isolated problem as a project?
>
> Jussi
>
> On Sat, Apr 10, 2021 at 11:35 AM Mike Crean via User <
> user at lists.gambas-basic.org> wrote:
>
> In the following code the WebTimer is not set to True when the code is
> executed !!
> Why??
>
> ' Gambas class file
>
> Export
> Public Cnt As Integer
>
> Public Sub WebForm_Open()
>   WebTimer1.Enabled = True
> End
>
> Public Sub WebTimer1_Timer()
>   Cnt = Cnt + 1
>   WebLabel1.Text = Cnt
> End
>
> Regards
> Mike
>
>
>
>
>
>
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20210411/fb32a646/attachment.htm>


More information about the User mailing list