Code Comments
Programming Forum and web based access to our favorite programming groups.Hi I've been looking at the threads here and haven't found a clear answer to the question: Is there or is it possible to implement an efficient timer control, class or algorithim in either of these products? By efficient I mean something that does not use a hard loop and will not eat CPU cycles. In most of the Microsoft family of Visual products visual timer controls are part of the product offering and these seem to be designed using system api's rather than loops so that overall performance is not degraded. Does Micro Focus have anything that's equivalent? Thanks Elliot
Post Follow-up to this message"eselick" <eselick@gmail.com> wrote in message news:1148480928.355811.205830@y43g2000cwc.googlegroups.com... > I've been looking at the threads here and haven't found a clear answer > to the question: > > Is there or is it possible to implement an efficient timer control, > class or algorithim in either of these products? > > By efficient I mean something that does not use a hard loop and will > not eat CPU cycles. In most of the Microsoft family of Visual products > visual timer controls are part of the product offering and these seem > to be designed using system api's rather than loops so that overall > performance is not degraded. > > Does Micro Focus have anything that's equivalent? If you are on Windows and you feel up to using the Windows' API directly, the timer objects created by the CreateTimer and CeateWaitableTimer functions are what the MS-Visual Anything 'native' functions use (see these functions in your Windows' API reference). Both utilize the normal thread-switching alogrithms of the Windows Operating system, essentially checking timer status at the same time it is checking that another thread may run.. that is, there is no "looping" other than what the operating system does anyway to parcel out CPU time amongst all users. No, I don't know how to implement these using the Microfocus / Net Express product(s), but I'm sure you can make WinAPI calls, so there simply must be a way to do it; perhaps someone here can point you in the right direction. (FWIW, IMNSHO Microsoft Visual Anything is designed for those less capable than the audience here). -- Michael Mattias Tal Systems, Inc. Racine WI mmattias@talsystems.com
Post Follow-up to this messageThanks Michael Are you aware of any example code for doing API calls in general in Net Exress? Elliot
Post Follow-up to this message"eselick" <eselick@gmail.com> wrote in message news:1148487127.608914.235600@i39g2000cwa.googlegroups.com... > Thanks Michael > > Are you aware of any example code for doing API calls in general in Net > Exress? Nah. I ain't done no COBOL for more than five years, and all that was procedural "batch-type" or "console display-accept" type code. But if you can figure out how to call a standard DLL you can do it, because that's all the WinAPIs are, a bunch (make that, "a **WHOLE** bunch) of functions in a bunch of DLLs. That said, if you are hooking into window procedures, then you may have to watch out for 'compiler-specific' quirks... much as you have to do with Microsoft Visual Anything. (Adding a little shameless self-promotion)...let's say find what you need for calling a function in a DLL, but are just not comfortable using all the system objects... you could always contract with someone who does understand those things, who could create for you a DLL with all the functions you need using the syntax you want.... someone like, well, myself. MCM
Post Follow-up to this message"eselick" <eselick@gmail.com> wrote in message news:1148487127.608914.235600@i39g2000cwa.googlegroups.com... > Thanks Michael > > Are you aware of any example code for doing API calls in general in Net > Exress? Hi Elliot, If you look under the Micro Focus SupportLine site at http://supportline.microfocus.com/e...mp.asp#Win32API , you will find a variety of examples of calling Windows APIs. (You may need to register/login to access this page). Hope this helps. SimonT.
Post Follow-up to this messageThanks for the help everyone. I think I'm going to run my COBOL program from an external scheduler. Why reinvent the wheel? Elliot
Post Follow-up to this message"eselick" <eselick@gmail.com> wrote in message news:1148575967.527613.67520@j73g2000cwa.googlegroups.com... > > I think I'm going to run my COBOL program from an external scheduler. > Why reinvent the wheel? Because Real Men don't need no stinkin' external schedulers. MCM
Post Follow-up to this messageOh well I guess I'll just have to email you a nasty reply in hex ... Michael Mattias wrote: > "eselick" <eselick@gmail.com> wrote in message > news:1148575967.527613.67520@j73g2000cwa.googlegroups.com... > > Because Real Men don't need no stinkin' external schedulers. > > MCM
Post Follow-up to this message"eselick" <eselick@gmail.com> wrote in message news:1149171778.449367.202680@c74g2000cwc.googlegroups.com... > Oh well I guess I'll just have to email you a nasty reply in hex ... How nasty can you get restricted to the letters A, B, C, D, E and F? (oh-oh, that was asking for it, wasn't it?) MCM
Post Follow-up to this messageeselick wrote: > Oh well I guess I'll just have to email you a nasty reply in hex ... > > Michael Mattias wrote: > > > Is that the same as sending a hex by email? Donald ;< )
Post Follow-up to this messagePowered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.