.NET Samples

  • Customizing Skins

    • Customizing XAML Skins for PowerBuilder.Net WPF Applications

    • customizing_skins.zip Download
  • dwskindemo

    • DataWindow skins Demo

    • dwskindemo_part1.zip Download
    • dwskindemo_part2.zip Download
  • PB Skins

    • PowerBuilder Skins

    • PBSkins.zip Download
  • Styles and Skins

    • Styles and Skins

    • Styles_and_Skins.zip Download
  • ActiveX OLE

  • Book OLE Demo

    • Demo of OLE from the SAMS PB 9 Advanced Client/Server Book. By Bruce Armstrong. Updated 6/29/2015.

    • ole_activex.zip Download
  • PowerBuilder example using MS Browser Control

    • PowerBuilder example using MS Browser Control (by Reed Shilts)

    • browse80.zip Download
  • Common Controls OCX Demo

    • Common Controls OCX Demo

    • common_dialog.zip Download
  • Create Spreadsheet From DataWindow using OLE

    • Copies a datawindow into Excel, using OLE. Based on the other OLE demo app. This version is a function, and filters out carriage returns and line feeds

    • Create Spreadsheet.zip Download
  • DocumentProperties

    • Demonstrates how to read the DocumentProperties for a Word document

    • documentproperties.zipDownload
  • Excel Demo

    • PB 12.5.2 example using OLE to exchange data from/to Excel. Save DW to Excel, call Excel function and return value to PB. P.S: if you get an error when opening the Excel file, please follow instructions from this link: click here Download

    • excel_ole.zipDownload
  • Excel through OLE Automation Demo

    • Demonstrates creating a workbook and copying data from DataWindows to worksheets. By Bruce Armstrong. Updated 6/29/2015.

    • Excel through OLE Automation demo.zipDownload
  • Outlook Demo

    • Sample code for using MS Outlook.

    • outlook_demo.zipDownload
  • Send a fax

    • PB10: Objects and sample application showing how to integrate Powerbuilder with the Windows XP Fax Services

    • Fax.zipDownload
  • Web Map Locator

    • PowerBuilder 12.5.2 - Example of integrating Internet mapping in a PB application

    • WebMap.zipDownload
  • Advanced Developers Toolkit

  • LeoTool

    • LeoTool is a set of utilities for PowerBuilder development. It includes export, import, search, color picker and sql format tools

    • LeoTool.zipDownload
  • Advanced PowerBuilder Utilities

  • APU Utilities

    • It's the Advanced PowerBuilder Utilities. Bruce Armstrong updated it to PowerBuilder 11 back in August of 2009. It contains the following: Cross Reference - Examines the relationships between the objects that make up a PowerBuilder application DataWindow Extended Attribute Synchronizer (DWEAS) - Updates attributes of existing DataWindow objects from the PowerBuilder extended attribute tables DataWindow SQL Verifier - Checks the syntax of the SQL used by existing DataWindow objects PowerBuilder Extended Attribute Reporter (PEAR) - Generates reports on the contents of the PowerBuilder extended attribute tables Stored Procedure Update - Creates PowerScript statements that use stored procedures to update the database through a DataWindow Object Search utility - Scans one or more PowerBuilder libraries, looking for objects or text within objects Instructions: Create a temporary folder and extract these four files to that folder.

    • apu_part1.zipDownload
    • apu_part2.zipDownload
    • apu_part3.zipDownload
    • apu_part4.zipDownload
  • Charting

  • FusionChartsFree

    • The freeware product that the PBwithFusionCharts is based on

    • FusionChartsfree.zipDownload
  • PBwithFusionCharts

    • Demo how to apply fusioncharts

    • chart.zipDownload
  • Using the Microsoft Chart Control

    • Demonstrates how to the use the Microsoft Chart Control add in for .Net 3.5 in a PowerBuilder Win32 application. Use Visual Studio 2008 to deploy the control. By Bruce Armstrong. Updated 6/29/2015.

    • graphcontrol.zipDownload
  • XML SWF Demo

    • XML SWF Demo.

    • XML SWF Demo.zipDownload
  • Compile

  • Auto increment build number

    • Auto increment build number

    • buildnumber.zipDownload
  • NetStart Example

    • NetStart Example

    • netstart_sample.zipDownload
  • OrcaScript

    • Orcascript examples.

    • buildfromsource.zipDownload
    • OrcaScript.zipDownload
    • recompile.zipDownload
  • Control Samples

  • Add enabled property

    • Simple demo of giving back Enabled property to some Microsoft controls (those that PowerBuilder's wrapper does not expose). Also demonstrates usage of undocumented INDIRECT variables.

    • enablecontrols9.zipDownload
  • Button Tooltip

    • Show Tooltips for Buttons more than one line.

    • buttonstooltip.zipDownload
  • Calendar Control

    • Using Windows built in calendar control from PB, from Regan Sizer.

    • Monthcal.zipDownload
  • Dockable Windows

    • Dockable Windows - Updated Version

    • DockWindowSource.zipDownload
  • DwTvEventDelay

    • Datawindow Treeview events with Time Delay using Timing Object

    • dwtveventdelay.zipDownload
  • Gradient API

    • How to draw a gradient... special thanks to Philip Salgannik

    • gradient.zipDownload
  • Model-View-Controller List

    • Courtesy of Chris Gross

    • mvclist.zipDownload
  • Outlook 2003 ShortcutBar

    • Outlook 2003 ShortcutBar - PB 10.5 - Final Version

    • ShortcutBar.zipDownload
  • PB control resize

    • Resizes all controls if window is resized

    • resize.zipDownload
  • PB Editor Control

    • Syntax highlighting control for PowerScript

    • PB Editor Control.zipDownload
  • PictureControl scrollable

    • resizable zoomable scrollable picturecontrol

    • picturecontrol_scrollable.zipDownload
  • PictureControl scrollable

    • PictureControl with Zoom, Scroll, Print capability Update

    • picturecontrol_scrollzoom.zipDownload
  • RTF

    • RTF Font Demo with Enhancements

    • rtf_font.zipDownload
    • RTF Font Demo (Version 2) rtf_font demo version 2 by Marci Wilken

    • rtf_font2.zipDownload
  • Tooltip for Command and Picturebuttons

    • Displays Tag Property as Tooltip when Mouse is within Control

    • buttonstooltip.zipDownload
  • Transparent Window

    • Transparent Window

    • Transparent-Window.zipDownload
  • TreeView

    • CWinMDI Explorer type control from Philip Salgannik

    • cwinmdi.zipDownload
    • Explorer type control

    • TaskBar.zipDownload
    • Resizable Treeview demo from Phil Kaufman

    • resizeabletreeview.zipDownload
    • Treeview Print with State and Overlay Pictures

    • treeviewprint.zipDownload
  • Use of InkPicture Control inside DataWindow

    • Use of InkPicture Control inside DataWindow

    • InkPicture Control.zipDownload
  • User Interfaces for Long Running Processes

    • User Interfaces for Long Running Processes (Courtesy of Chris Gross)

    • uiprocess.zipDownload
  • Wizard

    • Sonux_wizard Create simple wizard-dialogs without PFC

    • sonux_wizard.zipDownload
    • Wizard demo from Phil Kaufman

    • Phils_Wizard.zipDownload
    • Wizard Object A user object that can be used to create wizard interfaces from Philip Salgannik

    • mywizard_nopfc.zipDownload
  • XP ListBar

    • XP ListBar

    • XPListBar.zipDownload
  • Database

  • Access column info

    • The PB database painter doesn't show whether Access columns are 'required'. This utility will give you that information by Bruce Armstrong. Updated 6/29/2015

    • accesstool.zip Download
  • Access key info

    • The PB database painter doesn't show Access foreign keys. This utility will give you that information by Bruce Armstrong. Updated 6/29/2015.

    • accesstool2.zip Download
  • Export to Access

    • Demonstrates how to dynamically create an Access database and export data to it by Bruce Armstrong. Updated 6/29/2015..

    • createdatabase.zip Download
  • Adaptive Server Enterprise Demo

    • ASE Demo from SAMS Advanced Client/Server PB9 book Example by Bruce Armstrong. Updated 6/29/2015.

    • asedemo.zipDownload
  • DBSearch

    • Example of searching for a character string in various db objects in SQL Server 2000.

    • dbSearch.zipDownload
  • MS SQL Server

    • Sample code from Sanjiv Das article in PBDJ, April 2004

    • Das1104.zipDownload
  • Oracle

    • Calling Oracle Stored Procedures Guidelines. PowerBuilder 9 Calling Oracle Stored Procedures Guidelines

    • PBOracleSPCodeDesign.zipDownload
    • Demo Code from TechWave 2006 IDD477 session. Demo Code from TechWave 2006 IDD477 session by Bruce Armstrong. Updated 6/29/2015.

    • IDD477_demo.zipDownload
    • Image Demo Demo of storing/retrieving image data in blob columns and applying to window/datawindow image controls by Bruce Armstrong. Updated 6/29/2015.

    • image_demo.zipDownload
    • Oracle demo from SAMS PB9 Advanced Client Server book

    • pb9book.zipDownload
    • PBNav A utility for browsing Oracle database, written entirely in PB by Bruce Armstrong. Updated 6/29/2015.

    • pbnav.zipDownload
    • Simple RPCFUNC demo Very simple example of using RPCFUNC method for calling stored procedures by Bruce Armstrong. Updated 6/29/2015.

    • rpcfuncdemo.zipDownload
    • Using the DBMS_ALERT package from PowerBuilder. Using the DBMS_ALERT package from PowerBuilder by Bruce Armstrong. Updated 6/29/2015.

    • alert.zipDownload
    • Using the DBMS_PIPE package from PowerBuilder by Bruce Armstrong. Updated 6/29/2015.

    • dbmspipe.zipDownload
  • QueryBuilder

    • Build SQL Statements Graphically - Important - *View Readme File*

    • QueryBuilder.zipDownload
  • SQL Anywhere

    • Adaptive Server Anywhere Demo, ASA Demo from SAMS Advanced Client/Server PB9 book. Example by Bruce Armstrong. Updated 6/29/2015.

    • asademo.zipDownload
  • SQL Extract

    • Converts DataWindow PBSelect to ANSI SQL for use with the SQLExpert Tuning product

    • SQLExtract.zipDownload
  • SQLXTRACT 12.5.2

    • Converts Unicode (PB/IM 10.x, WS, DW.Net) DataWindow PBSelect to ANSI SQL for use with the SQLExpert or Quest Central DB Tuning products.

    • SQLExtract_PB12.5.2.zipDownload
  • Datawindow

  • Advanced DDDW

    • DDDW which is filtered based on another column in parent datawindow, from Philip Salgannik

    • advdddwc.zipDownload
  • ApplyDWStyle

    • A utility to clone display style between two datawindows.

    • applydwstyle.zipDownload
  • Autosize Height of Header and or Trailer

    • Autosize Height of Header and/or Trailer. The only band that has autosize height is the detail band. This is a way to simulate autosize height of the header and/or trailer by using nested reports. Retrieve d_main using demo db.

    • Autosize Height of Header and_or Trailer.zipDownload
  • CSV Import for DataWindow

    • NVO for Comma Separated Value (CSV) Datawindow and Datastore Import

    • nv_csv_import.zipDownload
  • DataWindow and table column list compare

    • A utility to ensure that any new columns in database tables are being captured by the datawindows that reference them by Bruce Armstrong. Updated 6/29/2015.

    • dwtabn.zipDownload
  • DataWindow Events

    • A small example which shows different datawindow events firing.

    • dwevents.zipDownload
  • DataWindow Header Sort

    • DataWindow Header Sort

    • headersort.zipDownload
  • DataWindow Print Multiple

    • DataWindow print multiple with preview

    • dwprintmultiple.zipDownload
  • DataWindow Tooltip Service

    • A service for providing tooltips on datawindows with a wrapper for Microsoft Common Control

    • dwttips_service.zipDownload
  • DataWindow userobject head sort

    • The userobject than can let the user click the head then sort the column

    • dwheadsort.zipDownload
  • Edit limit with table compare

    • A utility to ensure that the edit style limit value is in synch with the underlying database column by Bruce Armstrong. Updated 6/29/2015.

    • chkedt.zipDownload
  • Find Fast

    • Fast Find service to a datawindow, using an SLE English regional settings need to be set

    • sle_fast_find.zipDownload
  • Hottracking

    • An example of doing hottracking (mouserollover) on header text objects in grid datawindows

    • xmousetest.zipDownload
  • Sample keyboard number pad layouts

    • Sample keyboard/number pad layouts (via DataWindows) for supporting touchscreen applications. By Bruce Armstrong. Updated 6/29/2015.

    • touchscreen.zipDownload
  • XP Grid

    • Change your grid datawindow to look like XP

    • XP_Grid.zipDownload
  • Column Width Checker

    • Checks column widths to make sure that they can display the full amount of data from the column. The columnwidthchecker.zip is the PB 12.5 version. By Bruce Armstrong. Updated 6/29/2015.

    • columnwidthchecker.zipDownload
    • The original version that has not been migrated (columnwidthchecker_originalversion.zip) to PB 12.5 is also available. By Bruce Armstrong. Updated 6/29/2015.

    • columnwidthchecker_originalversion.zipDownload
  • DragNDropDW

    • DragNDrop V.1.01-1 by trebbi_a_tiscali_it

    • source-0.2.zipDownload
    • DragNDropDW v1.01

    • DragnDropDw.zipDownload
  • DW2Struct

    • PB11 utility to create structure representing datawindow data source. Useful for creating .Net web services where the data needs to be passed as an array of a structure. By Bruce Armstrong. Updated 8/04/2015.

    • dw2struct.zipDownload
  • f_evaluate_attribute

    • f_evaluate_attribute returns the attribute either as evaluated (expression) or the value (no expression)

    • f_evaluate_attribute.zipDownload
  • Far right object locator

    • Utility that reports the object farthest to the right in each DataWindow in a PBL (the one that causes blank page feeds when printed) by Bruce Armstrong. Updated 6/29/2015.

    • far_right.zipDownload
  • Multi Select Listbox for DataWindows

    • Multi Select Listbox for DataWindows

    • sample.zipDownload
  • Games

  • Breakout

    • The popular game written in PowerBuilder

    • breakout.zipDownload
  • FreeCell

    • The popular solitaire card game written in PowerBuilder

    • FreeCell.zipDownload
  • Simple Games

    • Simple Games including Bombs (MineSweeper), Reveal and Bombs

    • Games.zipDownload
  • Space Invaders

    • The Classic Atari game by Ulf Nilsson

    • spaceinvaders.zipDownload
  • Sudoku

    • Game Sudoku (Spanish Version)

    • sudoku.zipDownload
  • Times Tables

    • Multiplication (Times) Table Drill Application

    • TTables.zipDownload
  • WordSearch

    • Word Search Puzzle Generator

    • WordSearch.zipDownload
  • Yatzee

    • Yatzee the dice game

    • yatzy.zipDownload
  • General

  • cn_color

    • Provides easy access to system colors. Refer to the script header in the global function.

    • cn_color.zipDownload
  • Double Metaphone (SOUNDEX) Algorithm Demo

    • This is a PowerBuilder Port of Double Metaphone © 1998, 1999 by Lawrence Philips.

    • metaphone.zipDownload
  • Getting MAC-Address from PB

    • Getting MAC-Address from PB

    • getmac.zipDownload
  • MessageBox without buttons

    • Display Message without responding

    • PB_Message.zipDownload
  • Mime Encoding

    • Demonstrates how to do MIME encoding in PowerScript by Bruce Armstrong. Updated 6/29/2015 Note: while the routine works, it is extremely slow. Not intended for production use

    • mime.zipDownload
  • PB async data retrieval

    • Retrieve data and do something else until data arrives

    • async.zipDownload
  • pbdw2flex

    • Generate a Flex DataGrid in Flash from a PowerBuilder DataWindow (requires Flex SDK) by Bruce Armstrong. Updated 6/29/2015.

    • pbdw2flex.zipDownload
  • PB resize control

    • PowerBuilder resize control

    • resize.zipDownload
  • PowerBuilder's Icon files

    • In PowerBuilder 10.5, many of the icons used in PowerBuilder and InfoMaker were changed. The PB10_Icons.zip file contains 24 icon files and more than 500 bitmap files used in previous versions of the products.

    • PB10_Icons.zipDownload
  • Resizable Response Windows

    • Resizeable response window. This version works with or without a control menu by Bruce Armstrong. Updated 7/16/2015.

    • resize_response.zipDownload
  • SendKeys

    • Send Keys to Another Application. Demo with Wordpad.

    • SendKeys.pbl.zipDownload
  • Simple Error Handler

    • Error Handling made simple. Standardized non-modal error display, with print, print-all, save features

    • p3_Demo_ErrorHandler.zipDownload
  • Tool to create Messagebox calls

    • A little Tool to create code for messagebox calls

    • msbxpntr.zipDownload
  • IDE Utilities

  • .NET Features Analyzer

    • IDE Add-in to support .NET deployments

    • nfa.zip Download
  • Clean up Recent Workspaces list

    • This utility will clean up the Recent Workspace list by Bruce Armstrong. Updated 6/29/2015.

    • cleanupmru.zip Download
  • Customizing the PB IDE

    • Demonstrates how to add items to the PB New dialog, incorporate wizards, etc

    • customizing_the_pb_ide.zip Download
  • PowerBuilder Clip Sharing Tool

    • This simple tool allows to share (export/import) PowerScript clips among developers and for any compatible version of PowerBuilder

    • ShareClip.zip Download
    • This simple tool allow to share among others Powerscript clips from PowerBuilder and/or PocketBuilder. This is an enhanced version migrated to PB 11.2 of the previous published 'Powerbuilder Clip Sharing Tool'

    • ShareClip2.zip Download
  • InfoMaker

  • DW using Oracle Stored Procedure

    • Datawindow/Report using Oracle REF CURSOR

    • sp_as_source_for_dw.zip Download
  • InfoMaker Functions

    • Global functions for use in InfoMaker 8 - 10.5 reports. Also allows export of source code, import of PSR and SRD files

    • Im_functions.zip Download
  • PB9Book InfoMaker Examples

    • PB9Book IM examples, including updated imstyle9.pbl

    • 500404_example.zip Download
  • Internet

  • Winsock APIs

    • Use Winsock APIs to create Server or client sockets in PowerBuilder

    • Winsock APIs.zip Download
  • LDAP

  • LDAP Active Directory Authentication

    • Authenticate a user against a LDAP/AD server from a Powerbuilder client

    • pb2ldap.zip Download
  • LDAP Demo

    • LDAP Demo

    • ldap.zip Download
  • Menus

  • Add items to System menu

    • Use Windows API functions to add menu items to System menu by Bruce Armstrong. Updated 6/29/2015

    • sysmen.zipDownload
  • Split Column Menu

    • Use Windows API functions to create a split column menu by Bruce Armstrong. Updated 6/29/2015.

    • modmnu.zipDownload
  • Multimedia

  • Car MP3 player and synchronizer

    • Car MP3 player and synchronizer

    • Car mp3 player and synchronizer.zipDownload
  • CD Player

    • Fully functional Music CD Player (Uses MCI Command set) and low-level O/S API calls

    • PB9_CDPlayer2.1.zipDownload
    • CDPlayer_3.4.2.zipDownload
  • nv_mp3

    • Use Shell API to Get MP3 Tag Info and Play MP3s

    • nv_mp3.zipDownload
  • PB MP3

    • Simple MP3 player - tested on Win2k uses winmm.dll

    • PBMp3.zipDownload
  • Others

  • Animation Example

    • Windows Animation Code Example

    • Animation.zipDownload
  • Commenter

    • PBCommenter PB 12.5.2

    • commentr1252.zipDownload
  • Communication with OpenOffice Spellchecker

    • This is a small part of how to communicate with OpenOffice from OLE objects in PB

    • example.zipDownload
  • File Utilities

    • File Utilities

    • filefind.zipDownload
  • MSS

    • Marketing Support System Code Example

    • MSS.zipDownload
  • PowerBuilder .NET client to EAServer 6.3.1

    • Demonstrates use of the .NET EAServer client (in version 6.3.1) with PowerBuilder 12.5.2

    • pb1252eas631.zipDownload
  • PB Code Profiler

    • Demo showing how to use the profiler capabilities built into PowerBuilder

    • p3_Demo_Profiler.zipDownload
  • Profiler

    • Profiler Example

    • p3_Demo_Profiler.zipDownload
  • PSR Viewer

    • PSR File Viewer Utility for DataWindows saved in PSR format

    • PSRViewer.zipDownload
  • Source Control

    • Source Control example

    • GetCheckedOut.zipDownload
  • TabletPC Ink Control

    • Example of how to use Ink Controls in a PowerBuilder 10.2 application

    • Ink_Control Sample.zipDownload
  • Version Information

    • Version Information

    • version.zipDownload
  • PB Code Samples

  • CashTrak

    • A Personal Account Manager Application

    • CashTrak.zipDownload
  • Printer Utilities

  • Change printer

    • A pure PowerScript method for changing the printer PB uses for pre-PB8 versions of PB

    • printsetup.zipDownload
  • Dynamic Report

    • Dynamic Report using Tabular DataWindow

    • DynamicReport_Src.zipDownload
  • Enum Print Jobs

    • Demonstrates how to call the EnumJob function in the Windows API (PB9) by Bruce Armstrong. Updated 6/29/2015.

    • enumjobs.zipDownload
  • PowerPrinter

    • PowerPrinter is a 32-bit DLL that gives you access to all printer settings by means of simple APIs. Revised 7/15/2015.

    • inetwh32.zip Download powerprinter click here Download
  • System Tray

  • Icon Tray

    • An example of running an application as a system tray icon from Roland Smith

    • icontray.zipDownload
  • System Tray Example

    • System Tray Code Example

    • SysTrayCodeExample.zipDownload
  • Threading

  • MultiThreaded Count Example

    • MultiThreaded Count Example by 'Bugs'

    • sharedcount.zipDownload
  • MultiThreading Service

    • Extendable multi-threading service. Does not require PFC

    • Threading.zipDownload
  • Simple MultiThreaded Sample (PB11)

    • Source Code for Multithreaded sample application presented at Techselect UK 2007

    • multithreaded.zipDownload
  • Threads

    • Thread demo by Roy Kiesler

    • threads.zipDownload
  • WigglyWorms

    • Compares single threaded vs. multithreaded implementation of multiple worm-like shapes moving in a window control

    • WigglyWorms.zipDownload
  • Windows API

  • EnumProcesses

    • Determines a list of running processes using Win32 API calls

    • EnumProcesses.zipDownload
  • PowerBuilder Utilities DLL

    • A C++ wrapper DLL for some commonly asked for functionality:Bitwise operations, Networking, Numeric

    • pbutils_part1.zipDownload
    • pbutils_part2.zipDownload
  • Redirect Console Output

    • Use Windows API functions for redirecting a console output (STDOUT) into multiline edit or a log file

    • outputredirect.zipDownload
  • Size of API Structure Utility

    • To make various API calls from PowerBuilder, you need to know the size of the API structure. This C++ utility shows the sizes of many by Bruce Armstrong. Updated 7/16/2015.

    • sizeofstruct.zipDownload
  • WPF

  • PB Calc

    • Standard calculator written in PowerBuilder.Net, it shows how to embed XAML in PB WPF window

    • pb_calc.zipDownload
  • XML

  • PBDom Recursion

    • PBDOM XML Recursion Parse to TreeView

    • pbdom_recursion.zipDownload
  • UI from XML_WML

    • Creates a user interface on the fly from a XML document

    • PBXMLWML.zipDownload
  • XML2DW Wizard

    • Create a datawindow from a predefined XML syntax

    • xml2dw.zipDownload