Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Help Creating an NVO Timer

437 views
Skip to first unread message

John Jones

unread,
Oct 10, 2008, 9:21:22 AM10/10/08
to
Hello:

I am using PB 10.00 Build 4500
I am trying to create a countdown timer on a single w_main

From what I can gather, I NEED to create a non-visual object (NVO)
this is to keep me from "freezing" the .exe when it's being run and
timer active.

I have searched the 'net looking for some help. They all tell me
**what** to do but not **how** to do it.

I think when I create an NVO_timer, It needs to return a value of some
kind.

I have visited these links
"Cheat Sheet" for PFC/PB "Help"
Date Application was Compiled
Eric Aling's Home & PowerBuilder Page
Get data from the Internet
Getting Started
Ken Howe's PowerBuilder API Tips
PFC Guide
Pibbles.Net - Everything PowerBuilder
PowerBuilder 10.0 - Product Manuals
PowerBuilder Online Training Courses -
PowerBuilder Online Training Courses - Advanced Powerbuilder
PowerBuilder Tips & Tricks
PowerBuilder WebRing
powerbuilder: PowerBuilder Project
Schultz’s PowerBuilder Notes

and I have these TechNotes/Docs:
apptech.pdf
dwprgug.pdf
dwref1.pdf
dwref2.pdf
objcont.pdf
pbgs.pdf
pbnigref.pdf
pbug.pdf
psref1.pdf
psref2.pdf

Thank you for your time.

Roland Smith [TeamSybase]

unread,
Oct 10, 2008, 10:13:21 AM10/10/08
to
You can use the Timer event on the window. The Timer(x) function will cause
the Timer event to execute every x seconds.

Or you can create a Timer nvo object. You can read about it in the Help
file, look up 'Timer object' in the help index.

This thing about freezing is something completely different. If you need to
execute some code every so often and don't want it to lock the user
interface, you need to create a background thread using the SharedObjectxxx
functions.


"John Jones" <VOID.Re...@gmail.com> wrote in message
news:rjjue412cbm0thpfp...@4ax.com...

John Jones

unread,
Oct 10, 2008, 11:39:13 AM10/10/08
to
On 10 Oct 2008 07:13:21 -0700, "Roland Smith [TeamSybase]"
<rsmith_at_trusthss_dot_com> wrote:

>You can use the Timer event on the window. The Timer(x) function will cause
>the Timer event to execute every x seconds.

This is my w_main.open event:

time ls_sle_down
DateTime sys_datetime
sys_datetime = DateTime(Today(), Now())
Timer(.0011)


This is what I have currently for w_main.timer

DateTime sys_datetime
sys_datetime = DateTime(Today(), Now())
st_time.text = String(sys_datetime, "h:mm:ss AM/PM")
Timer(.0011, w_timer)

The page that got me thinking is
http://www.sybase.com/detail?id=1016220

Titled "Using external function calls in a timer object without
stoping the timer" typo and all. :)

Roland Smith [TeamSybase]

unread,
Oct 10, 2008, 1:44:00 PM10/10/08
to
That article suggests using Shared Objects which is what I said. It creates
a separate thread in the background to perform the processing.


"John Jones" <VOID.Re...@gmail.com> wrote in message

news:k4tue41cih097s998...@4ax.com...

0 new messages