Win32 API samples

This collection of code snippets used to be hosted on www.global-shared.com.
It is an old collection: it all began in 1996 or 1997, when Progress 8 was new and many of us were still using Windows 3.1 !!
Unlike wine or paintings, program code doesn't get better when it ages. You can find fragments that can be improved because Microsoft continuously expands their API, or are outdated because Progress has added features to the ABL so we don't need to use the WIN32 API anymore.


.NET + OpenEdge Webservices using ProDataSet

We are trying to create an application with a thought of SOA, for this we
have selected .Net UI and progress web services using prodataset.

Problem is that .net client is not able to find prodataset reference in
services which are taking dataset as input parameter (they need to create
an object of that type to pass to this service).


How to add a colored square in the titlebar through api

Sometimes it's neccessary to add a Caption in the titlebar to give extra information to the user of your application. The attached file does this, and makes sure the window got redrawn when windows triggers arive.
As you can see, many instances of msgblst32 are added on this window. The goal is to make it more the controlling window which always catches the events on the underlaying session applications. As every window needs its own ocx, I provided 40 instances which are hopefully enough to maintain every window.


4Each - Foro

En nuestro foro podrás encontrar toda la ayuda que necesites, códigos de ayuda y hasta cursos.


Ping.p

Hi,

has anybody change the program PING.p placed in Win 32 Api - Networking to accept the name of the host?

Thanks in Advance.

Baltazar


Line Chart

I am working on a project that requires representation of data using line chart to be displayed in a frame.

Is this possible in progress? Any advice?

Thanx in advance


How to get the 'WTSSessionID' out of the WTSQuerySessionInformation function??

I need to get the 'SessionID' from a Terminal Server Session.
I've already found a Progress example how to use the 'WTSQuerySessionInformation' to get the username (= WTSInfoClass = 5 => pointer to a null-terminating string).

To get the SessionId I need to call the same function but with the WTSInfoClass = 4 (= pointer to a ULONG variabele)
How can I do this??? I've changed the parameter from 5 to 4 but I don't get a result!!

I also want to use the same function but with the WTSInfoClass = 23 (= WTSClientInfo => pointer to a WTSCLIENT structure)


Microsoft statusbar activex control customization

Hello,

I have embedded Microsoft Statusbar activex control into our GUI application. The control is inside a smart frame and so that it can be easily included and customized for a container. I am using a imagelist activex control to display images inside the statusbar. The images (BMP, GIFS,JPEG,ICOM) looks stretched inside the statubar panel. The images are 16 X 16 resolution. Did anybody experienced similar problem. Can somebody help?

Thanks
Shanker


DB2Excel

Hi guys,
I tried to create a program that will generate code that will export table contents to excel
and wanted other people to test my project. (P.S. Please excuse my coding, I'm just a starter with progress :}).

This program is created using Openedge 10.1B and tested using Microsoft Excel 2007
DB2Excel is a program that automatically generates code for importing data to excel.

Step 1: db2Excel Collects tables from the database and makes them available for selection.
(if needed for schema preview, you can edit the source code to view system tables)


Attributes & Events of MS Treview(Please help..(:<)

I am trying to use use checkbox property of MS Treeview.
Does anybody has an idea where can I find the attributes & events of an activeX control?

What I'm trying to do is to:
1. Identify the number of Entries in a Treview
2. Loop for each Entry in a treeview. And lastly,
3. To identify if that item's checkbox is selected.

If you have any Idea, please send me code sample how to achieve this.

Thanx,
gsanchez


How to read data from a 3rd party device!!

Consider I have some devices connected to my system like RF-GUN or some other 3rd party devices, How can i get the data from that?

Also i need to know if there is some basic tutorials to start with this WINAPI Samples. I could find hands of examples from this forum, but to have a good start i hope a simple tutorials will do good. If anyone have basic tutorials on this can u please share it with me??? Plzzz guys...

Can anyone help me out???

Thanks in advance...


No-focus bug vs feature

Prior to OpenEdge 10.1, when you click a no-focus, flat button in a window the window does not get focus. It's z-order among other windows is unchanged.

In 10.1A this feature (Progress calls it a bug) is fixed. Clicking a no-focus button now sets the focus to the window containing the button.

I'm looking for a way to get the old behaviour back.


Codejock Docking Windows

I have been attempting to get codejocks docking panes working in a Progress V9 smart window.

Has anyone managed to get these components operating in a Progress window ?

I have managed to get the primary windows docking pane the launch and create a fresh window, then by use of the getparent() setparent() calls to user32.dll, these launched window becomes a child window in my parent window, but it seems the codejock component isnt doing any control.


ShellExecuteExA

I'm trying to track programs opened through open edge i.e. word, notepad, excel, etc. To do this I've tried using ShellExecuteExA which seem to be capable of passing back the PID if you specify the SEE_MASK_NOCLOSEPROCESS part of SHELLEXECUTEINFO. My problem is I can't figure out how to set this, everything so far has been based on wait until MS-Word finished printing section of OE Hive). Does anyone have any advice or code samples?


HELP GDI X PORGRESS

Good afternoon.
A customer had the "shining idea...". To show to graphs right-handers in the screen of a program progress.
I made the following one:
1º I declared gdi as one procedure external:

.

PROCEDURE Rectangle EXTERNAL “GDI.dll” :
DEFINE INPUT PARAMETER nLeftRectx AS LONG .
DEFINE INPUT PARAMETER nLeftRect AS LONG .
DEFINE INPUT PARAMETER nTopRect AS LONG .
DEFINE INPUT PARAMETER nRightRect AS LONG .
DEFINE INPUT PARAMETER nBottomRect AS LONG .
END PROCEDURE.

PROCEDURE PAINT :


MAPI Problem

Hi,

I downloaded the MAPI code that allows for multiple attachments. I ran the program and it created an e-mail message in my Outbox. The problem is that when I tried to run it again I get a Progress error telling me that it cannot find windows.i. It seems to make a mess of my path. Any ideas why this happens?

Stuart Richler
stuart@gtrdta.com


#
Syndicate content