So I’m working on a ‘dashboard’ style datawindow in an application which shows a grid of data along with some graphics so the user can easily see changes/important stuff. There are a number of reasons to use a grid datawindow for this, especially since they can easily be changed by the user to suit their…
- .ics
- .NET
- Active Directory
- C#
- Citrix
- COM
- Connection string
- Dashboard
- datawindow
- debug
- disaster prepardness
- ETL
- EVENTCREATE
- Facsys
- frogs
- games
- MDI
- mySQL
- ODBC
- OLEDB
- Outlook
- parenting
- PB.INI
- pfc
- Powerbuilder
- Powerbuilder OLE
- Powerbuilder Tutorial
- programming
- regasm
- REPORTEVENT
- SCOPE_IDENTITY
- source control
- SQL Anywhere
- SQL Native Client
- SQL Server
- TWAIN
- Uniface
- Visual Basic
- web service
- Windows API
- Windows Event Log
- Windows settings
PowerBuilder ‘Gotcha’ – Grid Datawindows with Picture Controls
I should have known this would happen…
So I’m encountering an issue in PowerBuilder where I’m creating a datawindow object from a dynamically built SQL statement and a user is getting some wonky results along with a cryptic “datawindow release number is incorrect” message. A quick Google and then… Fine time for a single search hit…
PowerBuilder – Using C# Visual Objects in PB Classic Applications
This article will explain how to build a COM visual component in C# using Visual Studio 2010; it is an extension of my earlier example of using the Interop Forms Toolkit to build a Visual Basic COM object. First you need to install the Microsoft Interop Toolkit (available here). Then download the C# Interop Form…
PowerBuilder – Timing Out a Windows Session
There are a variety of techniques to locking or timing out an application after a certain amount of inactivity. With earlier versions of Windows (XP and prior) a common approach was to invoke the screen saver via a Send command. send(handle(This),274,61760,0) This doesn’t work with Windows 7 (or Vista). Try the following: integer li_rc OleObject…
PowerBuilder – Using .Net Visual Controls in PB Classic Applications
This article describes the techniques and code used during my presentations at the Carolina Code Camp 2012 and at the May 2012 meeting of the North Carolina PowerBuilder User Group. The techniques described here utilize Visual Basic .Net (coded in Visual Studio 2010) with the Interop Forms Toolkit available from Microsoft. The Interop Forms Toolkit…
PowerBuilder – Resizing a Response Window or User Object
Here is a technique you can use to resize a response window or userobject as needed. It makes use of the GetWindowLong and SetWindowLong Windows API methods. The oldest reference I found to this is from Eric Aling back in 2000. In a nutshell, you are changing the border around the object to one which…
PowerBuilder – Discarding Rows with Find
It’s a fairly common practice to report on a set of data derived from a larger group of rows. There are many techniques to do this in code and with the methods available with datawindows/datastores. One typical approach is to use the Filter method. The problem with this is it requires another trip to the…
PowerBuilder – Determining if Controls Overlap
I had a situation where I needed to know if the user is clicking on a control which is underneath a rectangle on a datawindow. In this case the interior of the rectangle was transparent. ls_name = dwo.name IF (left(ls_name, 2) = 'r_') THEN // my standard rectangle naming convention ls_objects = this.Describe( 'DataWindow.Objects') ls_objects…
100 Days of PowerBuilder – Day 6 – Adding Controls to a Form
This is part of my project ‘100 Days of PowerBuilder’ which is a series of discussions focused on basic PowerBuilder development. Note: This article is written with examples created in PowerBuilder version 12.5. Most steps/examples will be identical with any version going back to 9. Lets add some additional controls to our main form and…
PowerBuilder ‘Gotcha’ – Enabled Property on Controls
I’m writing a generic datawindow processor service to look at the controls on any given datawindow. I’m using the Getobjectatpointer method to give me the name of the current control (dwo.Name can be used as well) but I can’t get anything for a single control. Hmmmm…. To make things more interesting it’s a PB generated…