[Gambas-user] WebForm

Jussi Lahtinen jussi.lahtinen at gmail.com
Sun Apr 11 05:07:46 CEST 2021


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/d6ef0b3b/attachment.htm>


More information about the User mailing list