Convert PowerBuilder to C#
Delivering you a high-quality result in due time
Get started. Request a quoteDelivering you a high-quality result in due time
Get started. Request a quoteFact 1/6
Migration does not require labor-intensive development of new functionality from scratch. Your application will be converted to a new technology while maintaining the original functionality
Fact 2/6
Automated conversion implies preserving the initial architecture which is easier to maintain. The app architecture, can also be transformed, for example, from desktop to the web to improve accessibility and scalability
Fact 3/6
Migrating an application is much faster than creating a new one from scratch. Automated migration with Ispirer Toolkit minimizes manual effort and may speed up the delivery by 2-3 times
Fact 4/6
Migrating PowerBuilder to modern architectures or platforms can upgrade your application, making it easier to maintain, update, and extend in the long term run
Fact 5/6
Through conversion, you can optimize the application's architecture and infrastructure, improving scalability and performance without the need to rebuild everything
Fact 6/6
To perform the conversion, we go by your source code. There is no need to have detailed documentation in place to start the conversion as is the case with development
Ispirer Ecosystem automates your migration routine to enable quick and smart transformation of any application. Double the migration speed with our comprehensive solutions.
Unleash the reinforced application
Save your time
Do it for 5 minutes
CodeWays is a tool for automated application conversion that translates code from one programming language to another automatically, while preserving the initial functionality of an app. Using an intelligent proprietary algorithm, the tool analyzes the syntax, semantics, mapping data types, control structures, function calls, and code structures that do not have equivalents in a target technology.
Based on the analysis, CodeWays applies all the relevant conversion rules from its knowledge base core and translates PowerBuilder source code to C#.
App target code
App target code with converted ESQL
Files with SQL code for the target DB
*Embedded SQL are SQL statements written inline with the program source code, of the host language.
Dive into the tool’s features
More than 2K users use this way to
successfully convert their application code
Ispirer Toolkit analyzes all object dependencies during the conversion process and provides not only line-by-line conversion, but resolves type conversions as well. The software understands and transforms the necessary inheritance dependencies. It parses the entire source code, builds an internal tree with all the information about the objects, and uses it in the migration process.
PowerBuilder
long var1 long var2[] string var3 datetime var4 boolean var5 decimal var6 integer var7 any var8
→ C# WPF
int? var1 = 0; UnboundedArray < int? > var2 = new UnboundedArray < int? >(); string var3 = string.Empty; DateTime? var4 = new DateTime(1900, 1, 1); bool? var5 = false; decimal? var6 = null; int? var7 = 0; object var8 = new object();
PowerBuilder
public function string sample_function(); return "end" //do logic end function
→ C# WPF
public string sample_function() { return "end"; //do logic }
PowerBuilder
protected subroutine sample_sub (string v_app); v_app = "" //do logic end subroutine
→ C# WPF
public void sample_sub(string v_app) { v_app = ""; //do logic }
PowerBuilder
integer i if true then i = 1 else i = 2 if true then i = 3 end if
→ C# WPF
int? i = 0; if (true) { i = 1; } else { i = 2; } if (true) { i = 3; }
PowerBuilder
For lv_count = 1 to 10 lb_units[lv_count].Visible = TRUE Next
→ C# WPF
for (lv_count = 1; lv_count <= 10; lv_count ++) { lb_units[lv_count - 1].Visibility = Visibility.Visible; }
PowerBuilder
IDX = 0 do while true if IDX = 10 then exit IDX = IDX + 1 loop
→ C# WPF
idx = 0; while (true) { if (idx == 10) { break; } idx = idx + 1; }
PowerBuilder
try IDX = 1 / 0 catch (Exception ex ) IDX = 100 FINALLY IDX = IDX * 2 end try
→ C# WPF
try { idx = 1 / 0; } catch (Exception ex) { idx = 100; } finally { idx = idx * 2; }
PowerBuilder
integer some_id boolean cond CHOOSE CASE some_id Case IS < 0 cond = False CASE 0 TO 2 cond = True some_id = 200 Case IS > 0 cond = True CASE ELSE cond = False some_id = 0 END CHOOSE
→ C# WPF
int? some_id = 0; bool? cond = false; if (some_id < 0) { cond = false; } else if (some_id >= 0 && some_id <= 2) { cond = true; some_id = 200; } else if (some_id > 0) { cond = true; } else { cond = false; some_id = 0; }
PowerBuilder
global type s_2 from structure long field_1 end type s_2 param1[] INSERT INTO TAB1 ( COL1 , COL2 ) VALUES ( :param1[1].field_1, :param1[2].field_1 );
→ C# WPF
public class s_2 { public int? field_1 = 0; } UnboundedArray< s_2 > param1 = new UnboundedArray< s_2 >(); var dbCmd_ = new SACommand(); dbCmd_.CommandText = "INSERT INTO TAB1 " + " ( " + " COL1 , COL2 " + " ) " + " VALUES " + " ( " + " :field_1, " + " :field_1 " + " )"; dbCmd_.Parameters.AddWithValue("field_1", param1[0].field_1 ?? (object) DBNull.Value); dbCmd_.Parameters.AddWithValue("field_1", param1[1].field_1 ?? (object) DBNull.Value); dbCmd_.CommandType = CommandType.Text; AppGlobalVariables.sqlca.ExecuteNonQuery(dbCmd_);
PowerBuilder
String v_uname[] Long v_unum[] Int v_count = 1 DECLARE c_unit CURSOR FOR SELECT U_NAME, U_NUM FROM UNT WHERE A_NUM = 10; OPEN c_unit; FETCH c_unit INTO :v_uname[v_count],:v_unum[v_count]; v_count ++ Do While SQLCA.SQLCode = 0 FETCH c_unit INTO :v_uname[v_count],:v_unum[v_count]; v_count ++ Loop CLOSE c_unit;
→ C# WPF
UnboundedArray< string > v_uname = new UnboundedArray< string >(); UnboundedArray < int? > v_unum = new UnboundedArray < int? >(); int? v_count = 1; var dbCmd_c_unit = new SACommand(); dbCmd_c_unit.CommandText = "SELECT U_NAME, U_NUM " + " FROM UNT " + " WHERE A_NUM = 10"; dbCmd_c_unit.CommandType = CommandType.Text; var c_unit = sqlca.ExecuteReader(dbCmd_c_unit); if (c_unit.Read()) { v_uname[v_count] = c_unit?.GetString(0); v_unum[v_count] = c_unit?.GetInt32(1); } else { sqlca.SqlCode = 100; } v_count ++; while (sqlca.SqlCode == 0) { if (c_unit.Read()) { v_uname[v_count] = c_unit?.GetString(0); v_unum[v_count] = c_unit?.GetInt32(1); } else { sqlca.SqlCode = 100; } v_count ++; } c_unit.Close(); c_unit.Dispose();
Ispirer Toolkit automatically converts not only a single piece of code, but an entire application. Complex code will require customization of the toolkit
PowerBuilder programs consist of Workspaces (starting from PB 8.0 and higher, these are .pbw files). Conceptually, they are similar to Solution. These are text files consisting of paths to the Target files (.pbt files) that correspond to the concept of Project. The Target files are in text format, and each contains paths to the PowerBuilder libraries (.pbl files that store source code files in binary format). Typically a library with the same name as the Target file has a .sra entry point file.
To convert a PowerBuilder application, you need to extract all source files from the appropriate Workspace libraries (or Target, if PB version is less than 8). You can download Ispirer PowerBuilder Metrics to get a statistical report on PB sources, as well as extract source files from PowerBuilder libraries using Workspace, or a set of Target files, or a set of particular PB libraries (.pbl files) that need to be converted.
Once the source code is extracted, for each PowerBuilder library file, a corresponding folder named library will be created with all the source code extracted. The folders will contain source files with the following file extensions:
Now you can use Ispirer CodeWays to convert it to your chosen target technology. Basic source type conversion by extension:
After the conversion, you need to create a WPF application desktop project in Visual Studio and add the converted files from the results folder to it. There is the Ispirer framework for converting PowerBuilder to C# WPF (IspirerFramework*) in the results folder. It contains 4 or more projects that should be added to the solution and used in the main project with the conversion results as references. The events are converted to the corresponding events of the target technology.
Note: this is a special framework provided by Ispirer. It extends the target technology to enable specific source code features.
Ensuring high security and performance standards is what we do best, thanks to our impressive expertise in building reliable and scalable solutions.
Our team has gained a wide pool of expertise in various programming languages, from the rarest to the most popular ones.
We comply with ISO 27001 security management requirements with comprehensive policies and processes, advanced security technology, and skilled professionals.
We employ Ispirer proprietary tools, underscoring our dedication to delivering the utmost reliability and performance solutions.
The toolkit is compiled daily and continually integrates dozens of new conversion rules, enhancing the automation capabilities.
Epicor, University of Maryland, Splice Machine and more have adopted CodeWays to boost their innovation life-cycle accelerate and manage their end-to-end innovation lifecycle
Take control of your application
сonversion now
Do it for 5 minutes