Tech Articles


Git Enhancements in PowerBuilder 2017 R3


Support for using Git as a source control system without going through a bridge product was added in 2017 R2 and covered in a previous blog post.  In this blog post we're going to look at the enhancements that were added to that feature in 2017 R3. 

Read more

Avoid Potential SQL Server tempdb log file issue when switching from Table Variables to Temporary Tables in a Stored Procedure called by a Data Window retrieval


In SQL Server it is generally a good idea to use temporary tables, rather than table variables within your stored procedures. Temporary tables perform much better, particularly with large volumes of data, as SQL Server is able to compile statistics on the data in temporary tables. However, if you are calling your stored procedures from a Powerbuilder application,  you may find that the switch to temporary tables has an unwanted side effect. Here is how the unwanted side effect comes around and what to do about it. 

https://www.selecttop.co.uk/440194269
 
https://www.youtube.com/watch?v=7QK-N6dQxNg

ALTERNATIVA PARA CONSUMIR WEB SERVICES REST JSON VERSIONES ANTERIORES (6.5, … , 11.5)


Con los nuevos sistemas una de las cosas que hoy en día escuchamos es: tenemos un web services donde puedes consultar…

Por lo que ante esta necesidad y teniendo un sistema desarrollado originalmente en powerbuilder 6.5 ( les traigo esta solución.

Un “consumer” de WS REST

Para hacer este ejemplo utilizaremos objetos no visuales, principalmente el objeto internetresult.

Read more

Calling SHGetKnownFolderPath from PowerBuilder


Up through Windows XP, if you wanted to get the physical location of certain defined folders (e.g. the users Documents folder), you would use the SHGetFolderPath function in the Windows API.  Roland Smith has examples of using that on his Topwiz Software site.  That function continues to work in later versions of Windows, although it's basically a wrapper for the SHGetKnownFolderPath function.

SHGetFolderPath uses CSIDL values, whereas SHGetKnownFolderPath uses KnownFolderID GUIDs.  One difference is that there are a lot more KnownFolderIDs than there are CSIDLs.  That means some of the defined folder locations you may want to get the physical location for can't be accessed through the older SHGetFolderPath method.  And that's exactly the situation I ran into.


I needed to find the user's Downloads folder, and there isn't a CSIDL value for that.  So, I needed to see how to call the SHGetKnownFolderPath function from PowerBuilder.  As with many OLE and Windows API calls, it can save you a lot of time if you can find some Visual Basic code that does what you need to do, and you can convert the syntax.  And fortunately, I found some that did this.

Read more

How to Emulate C# Style Enumerations in PowerScript


This article describes how you can emulate C# style enumeration types in PowerScript since PowerScript currently does not support creation of custom enumerations. Personally, I found myself in need of such enumerations when interfacing to Microsoft Word/Excel using OLE Automation.

Calls to Word or Excel functions without enumerated values (or named constants) are incredibly hard to read and understand. An example:

oleDocument.Selection.Move( 10, 2)
oleDocument.Selection.Move( 12, 4)

Using C# style enumerations, the same code could read like this:

oleDocument.Selection.Move( wdUnits.Row, 2)
oleDocument.Selection.Move( wdUnits.Cell, 4)

Read more

DEPURAR EN POWER BUILDER CONSEJOS Y TRUCOS


  • Insertar un breakpoint.- Ejecute la opción de menú principal: Edit/ Insert BreakPoint
    • Requisito: Debes estar en el editor de código (script) .
  • Inicializar el depurador. Ejecute la opción de menú principal: Run / Debug nombre de su aplicación
    • Ejecute la opción Debug  / Start nombre de su aplicación
  • Ejecutar línea por línea.- F8
  • Detener el depurador.-  Debug/Stop
  • Ver el contenido de una variable.—Seleccione la variable, dar click derecho y escoger la opción quickwatch
    • Requisito: Debe estar ejecutándose la aplicación en modo de depuración

 

Truco: Algunas veces tenemos un error en tiempo de ejecución que nos hace que Powerbuilder se cierre, para localizar en donde ocurre esto la opción Depurar en tiempo de ejecución ayuda mucho.

Read more

PowerBuilder 2017 R2 New Feature: Git source control support


In a previous blog article we looked at the new feature of PowerBuilder 2017 R2 for Subversion source control support. In this blog article we're going to look at a very similar feature, Git source control support.  I'm not going to go through the history of source code support in PowerBuilder again, I'd refer you to that previous blog article for that.  We're going dive straight in to how the Git feature works.

Setting up Git

For this demo, we're going to use Bonobo Git Server.  One reason I like it is because it provide a web based admin console for managing the server, so I don't have to use the Git command line to do that.

Because it's an ASP.Net application, the machine where we're going to install it must have IIS and the .Net Framework 4.6 installed on it.  To install Bonobo Git once you've downloaded it you simply need to:

Read more

Find Articles by Tag

Application PDFlib PowerServer Web TLS/SSL OAuth ActiveX CI/CD Migration Service License Charts Array NativePDF Database Connection Web Service Proxy HTTPClient PowerBuilder Compiler Menu Filter Event Handling TFS Event CoderObject Excel Debugger Stored Procedure SqlModelMapper SnapObjects Windows OS Syntax Configuration DataWindow JSON RESTClient Automated Testing Authorization 32-bit Source Code Variable Event Handler Bug iOS Import JSON PDF WebBrowser Validation Class Interface Installation BLOB Import Database Profile PFC Open Source Mobile RibbonBar Branch & Merge Export JSON Jenkins Messagging DragDrop Script Model .NET Std Framework OAuth 2.0 Web API Design Graph MessageBox REST 64-bit Windows 10 Icons Resize Source Control Database Table Data Trial Error COM SnapDevelop UI Modernization Visual Studio Linux OS WinAPI Oracle .NET Assembly Debugging Transaction PowerScript (PS) Deployment SqlExecutor Platform RibbonBar Builder DevOps API Authentication CrypterObject UI GhostScript Export Testing RichTextEdit Control DLL SQL Server C# PBVM TortoiseGit OLE DataWindow UI Themes ODBC SQL File OrcaScript PowerBuilder Encoding PostgreSQL TreeView External Functions Repository Database Table JSON Database Painter Outlook Performance Azure Debug PostgreSQL ODBC driver Data Android JSONGenerator Window Elevate Conference Git .NET DataStore SVN Icon XML Database Object Database Table Schema Expression Encryption Text SDK Sort PowerServer Mobile IDE PBDOM PBNI Database PowerBuilder (Appeon) SOAP InfoMaker JSONParser DataType