You are currently browsing the Programming category

PowerBuilder ‘Gotcha’ – Strings, Describe and Position Attributes

Posted on September 6, 2012 at 6:40 pm in

So I’m getting the position attributes of a column in a datawindow to aid in the display of another visual object. What I initially coded was this: ll_open_x = Long(adw.describe(as_colname + '.X') + & adw.describe(as_colname + '.height')) + 10 I run the window and my visual object is no where to be seen. Looking in…

PowerBuilder ‘Gotcha’ – Strings, Describe and Position Attributes - the full story »

PowerBuilder ‘Gotcha’ – Invalid Expression Error Message

Posted on August 31, 2012 at 6:58 pm in

So customer support calls regarding an issue a client is experiencing on a periodic basis. The receive an error ‘Invalid Expression’. To make things worse they get a series of these messages popping up and eventually the application crashes. Great. So we look at the datawindow object on the application window they are having issues…

PowerBuilder ‘Gotcha’ – Invalid Expression Error Message - the full story »

Software Application Design – Required Reading

Posted on August 15, 2012 at 7:58 pm in

If you are involved in any way with software design and programming, you really must read the paper Magic Ink, Information Software and the Graphical Interface by Bret Victor. While you are at it, check out his entire web site worrydream.com. One point of particular interest to me was the section on ‘inferring content from…

Software Application Design – Required Reading - the full story »

Sending iCalendar events via a .Net Assembly and SQLServer stored procedure

Posted on July 31, 2012 at 5:01 pm in

As I’ve mentioned in earlier posts, the iCalendar format is a standard way to send event information to a variety of email/scheduling systems (Outlook, Google, etc.). Here is a way to set it up so that you can simply call a stored procedure to send the event. This assumes you have SQL Server set up…

Sending iCalendar events via a .Net Assembly and SQLServer stored procedure - the full story »

PowerBuilder ‘Gotcha’ – SyntaxFromSql and System Fonts

Posted on July 12, 2012 at 5:56 pm in

So a user of an application I work on is getting an error when opening a window which contains a dynamic datawindow. The open process reads a table and then dynamically creates a grid datawindowobject with the same number of columns as the data which is retrieved from the table. The process itself uses the…

PowerBuilder ‘Gotcha’ – SyntaxFromSql and System Fonts - the full story »

PowerBuilder ‘Gotcha’ – Grid Datawindows with Picture Controls

Posted on June 27, 2012 at 6:14 pm in

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…

PowerBuilder ‘Gotcha’ – Grid Datawindows with Picture Controls - the full story »

PowerBuilder – Using C# Visual Objects in PB Classic Applications

Posted on June 18, 2012 at 5:16 pm in

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 – Using C# Visual Objects in PB Classic Applications - the full story »

PowerBuilder – Timing Out a Windows Session

Posted on June 12, 2012 at 6:25 pm in

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 – Timing Out a Windows Session - the full story »

PowerBuilder – Using .Net Visual Controls in PB Classic Applications

Posted on June 5, 2012 at 5:27 pm in

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 – Using .Net Visual Controls in PB Classic Applications - the full story »

PowerBuilder – Resizing a Response Window or User Object

Posted on May 23, 2012 at 5:16 pm in

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 – Resizing a Response Window or User Object - the full story »

Top