Exporting PowerBuilder Source Code to Text Files

News group sybase.public.powerbuilder.general

Exporting PowerBuilder Source Code to Text Files 2010-12-22 20:31
Hello,

We are trying to provide the customer the PowerBuilder
source code for review. The problem the customer does not
have a copy of PowerBuilder. Is there any other tool to
export the source code in a text file without having to
address each object within PowerBuilder.

Thanks,

LaChandra...
Menu
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-23 20:20
Hi LaChandra;

Its easy and built-in to PowerBuilder (except the new PB 12.net)!

Just use the native source code support in PB. After you activate the native
SCC and point it to a folder - just "check-in" all the objects in your
workspace/target (Add to SCC). When you have done that, all the exported
object's source code will be in the folder where you targeted in the native
SCC interface to use.

HTH

Regards ... Chris
President: OSUG / STD Inc.
Blog: http://chrispollach.blogspot.com
PBDJ: http://chrispollach.sys-con.com
SourceForge: http://sourceforge.net/projects/stdfndclass


Hello,

We are trying to provide the customer the PowerBuilder
source code for review. The problem the customer does not
have a copy of PowerBuilder. Is there any other tool to
export the source code in a text file without having to
address each object within PowerBuilder.

Thanks,

LaChandra...
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-23 22:52
Correction Chris

>Its easy and built-in to PowerBuilder (except the new PB 12.net)!

Source exporting is not absolutely necessary in PB .NET when the
requirement is to view the code since source is stored in plain text
files in the PBL folder.  So its even easier to access source code
outside the IDE in PB 12 .NET than in Classic

However source importing is still necessary since it creates the
directory entry in the PBLX file
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-24 01:22
Hi Yakov;

Thanks for the good tip on PB 12.net. I was talking about native SCC in
classic. But you are 100% on the money that PB 12.net keeps all object
source code in a folder (one per PBL). So all you would need to do is copy
all the *.SR* files in each PBL like folder to one location and then you
would have the same result as native SCC's target folder.

Merry Christmas!

Regards ... Chris
President: OSUG / STD Inc.
Blog: http://chrispollach.blogspot.com
PBDJ: http://chrispollach.sys-con.com
SourceForge: http://sourceforge.net/projects/stdfndclass


Correction Chris

>Its easy and built-in to PowerBuilder (except the new PB 12.net)!

Source exporting is not absolutely necessary in PB .NET when the
requirement is to view the code since source is stored in plain text
files in the PBL folder.  So its even easier to access source code
outside the IDE in PB 12 .NET than in Classic

However source importing is still necessary since it creates the
directory entry in the PBLX file
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-23 17:08
If you use a file based source control program like Visual Source Safe
it's as easy as GLVing the project in VSS. That will get you all objects
in all pbls in seconds.

Me thinks anytime someone outside my company wants to "review" my source
code they want to port/rewrite it in something else. Just call me
paranoid. :)

hth,
Mark

>Hello,
>
>We are trying to provide the customer the PowerBuilder
>source code for review. The problem the customer does not
>have a copy of PowerBuilder. Is there any other tool to
>export the source code in a text file without having to
>address each object within PowerBuilder.
>
>Thanks,
>
>LaChandra...
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-22 20:53
PBL Peeper (http://www.techno-kitten.com/PreRelease411/setup.exe) does this, but
it also lets people read PBLs without the PowerBuilder IDE in a much more
readable form than export files. It's been used by people like testers who
needed to read the code, but didn't have the IDE.

Good luck,

Terry and Sequel the techno-kitten

On 22 Dec 2010 11:31:41 -0800,
in sybase.public.powerbuilder.general

>We are trying to provide the customer the PowerBuilder
>source code for review. The problem the customer does not
>have a copy of PowerBuilder. Is there any other tool to
>export the source code in a text file without having to
>address each object within PowerBuilder.
*********************************
Build your vocabulary while feeding the hungry
http://www.freerice.com
*********************************
Newsgroup User Manual
=====================
TeamSybase <> Sybase employee
Forums = Peer-to-peer
Forums <> Communication with Sybase
IsNull (AnswerTo (Posting)) can return TRUE
Forums.Moderated = TRUE, so behave or be deleted
*********************************

Sequel's Sandbox: http://www.techno-kitten.com
Home of PBL Peeper, a free PowerBuilder Developer's Toolkit.
Version 4.0.4 now available at the Sandbox
PB Futures updated June 25/2008
See the PB Troubleshooting & Migration Guides at the Sandbox
^ ^
o o
=*=
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-22 21:27
To export (dump) source..
http://www.sqlbatch.com/pd/

hth

Arnd



>PBL Peeper (http://www.techno-kitten.com/PreRelease411/setup.exe) does this, but
>it also lets people read PBLs without the PowerBuilder IDE in a much more
>readable form than export files. It's been used by people like testers who
>needed to read the code, but didn't have the IDE.
>
>Good luck,
>
>Terry and Sequel the techno-kitten
>
>On 22 Dec 2010 11:31:41 -0800,
>in sybase.public.powerbuilder.general
>
>>We are trying to provide the customer the PowerBuilder
>>source code for review. The problem the customer does not
>>have a copy of PowerBuilder. Is there any other tool to
>>export the source code in a text file without having to
>>address each object within PowerBuilder.
>*********************************
>Build your vocabulary while feeding the hungry
>http://www.freerice.com
>*********************************
>Newsgroup User Manual
>=====================
>TeamSybase <> Sybase employee
>Forums = Peer-to-peer
>Forums <> Communication with Sybase
>IsNull (AnswerTo (Posting)) can return TRUE
>Forums.Moderated = TRUE, so behave or be deleted
>*********************************
>
>Sequel's Sandbox: http://www.techno-kitten.com
>Home of PBL Peeper, a free PowerBuilder Developer's Toolkit.
>Version 4.0.4 now available at the Sandbox
>PB Futures updated June 25/2008
>See the PB Troubleshooting & Migration Guides at the Sandbox
>^ ^
>o o
>=*=
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-23 10:40
I also find the PBLDump tool a great one!
Here's a sample batch file to export one PBL-file in a subfolder:

@echo off
if "%1" == "" goto help

@echo  - Exporting %1
if not exist %1 goto not_found
@md "PBLEXP - %1"
@cd "PBLEXP - %1"
if not exist ..\%1 goto delete_directory
for %%1 in ("*.*") do del %%1
@pbldump -es ..\%1 *.* >NUL
@cd..
@echo  - Exporting %1 ... Done!
goto end

:delete_directory
@cd..
@rd %1.dir
@echo Only short filespec (without directories) is allowed!
goto end

:help
@echo --------------------------------------------------------------
@echo Purpose : This program exports all entries of a given PBL-file
@echo Usage: %0 arg1
@echo Arguments: arg1 - PBL-file
@echo --------------------------------------------------------------
goto end

:not_found
@echo  - Exporting %1 ... FILE NOT FOUND!

:end


To use this batch file (let's name it pbl_exp.bat), put it along with the
pbldump.exe tool in a folder accessible within the PATH. Then go to the
folder where your PBLs reside and execute:
pbl_exp yourlibrary.pbl

Regards,
Ivaylo

>
>To export (dump) source..
>http://www.sqlbatch.com/pd/
>
>hth
>
>Arnd
>
>
>On 22 Dec 2010 11:53:23 -0800, "Terry Voth [TeamSybase]"
>
>>PBL Peeper (http://www.techno-kitten.com/PreRelease411/setup.exe) does
>>this, but
>>it also lets people read PBLs without the PowerBuilder IDE in a much more
>>readable form than export files. It's been used by people like testers who
>>needed to read the code, but didn't have the IDE.
>>
>>Good luck,
>>
>>Terry and Sequel the techno-kitten
>>
>>On 22 Dec 2010 11:31:41 -0800,
>>in sybase.public.powerbuilder.general
>>
>>>We are trying to provide the customer the PowerBuilder
>>>source code for review. The problem the customer does not
>>>have a copy of PowerBuilder. Is there any other tool to
>>>export the source code in a text file without having to
>>>address each object within PowerBuilder.
>>*********************************
>>Build your vocabulary while feeding the hungry
>>http://www.freerice.com
>>*********************************
>>Newsgroup User Manual
>>=====================
>>TeamSybase <> Sybase employee
>>Forums = Peer-to-peer
>>Forums <> Communication with Sybase
>>IsNull (AnswerTo (Posting)) can return TRUE
>>Forums.Moderated = TRUE, so behave or be deleted
>>*********************************
>>
>>Sequel's Sandbox: http://www.techno-kitten.com
>>Home of PBL Peeper, a free PowerBuilder Developer's Toolkit.
>>Version 4.0.4 now available at the Sandbox
>>PB Futures updated June 25/2008
>>See the PB Troubleshooting & Migration Guides at the Sandbox
>>^ ^
>>o o
>>=*=
>
Re: Exporting PowerBuilder Source Code to Text Files 2010-12-23 15:05
Yes, but how useful can exported Powerscript *.SR files be?  Especially
datawindow SRD files, and descendent objects, where a good percentage of
that object's "code" lives higher in the ancestor chain.

I think PB objects must be viewed within the context of the application or
target - and the only way I know of to do this without installing PB is to
use PBLPeeper.

Paul Horan[Sybase]
http://paulhoran.ulitzer.com

>I also find the PBLDump tool a great one!
>Here's a sample batch file to export one PBL-file in a subfolder:
>
>@echo off
>if "%1" == "" goto help
>
>@echo  - Exporting %1
>if not exist %1 goto not_found
>@md "PBLEXP - %1"
>@cd "PBLEXP - %1"
>if not exist ..\%1 goto delete_directory
>for %%1 in ("*.*") do del %%1
>@pbldump -es ..\%1 *.* >NUL
>@cd..
>@echo  - Exporting %1 ... Done!
>goto end
>
>:delete_directory
>@cd..
>@rd %1.dir
>@echo Only short filespec (without directories) is allowed!
>goto end
>
>:help
>@echo --------------------------------------------------------------
>@echo Purpose : This program exports all entries of a given PBL-file
>@echo Usage: %0 arg1
>@echo Arguments: arg1 - PBL-file
>@echo --------------------------------------------------------------
>goto end
>
>:not_found
>@echo  - Exporting %1 ... FILE NOT FOUND!
>
>:end
>
>
>To use this batch file (let's name it pbl_exp.bat), put it along with the
>pbldump.exe tool in a folder accessible within the PATH. Then go to the
>folder where your PBLs reside and execute:
>  pbl_exp yourlibrary.pbl
>
>Regards,
>Ivaylo
>
>>
>>To export (dump) source..
>>http://www.sqlbatch.com/pd/
>>
>>hth
>>
>>Arnd
>>
>>
>>On 22 Dec 2010 11:53:23 -0800, "Terry Voth [TeamSybase]"
>>
>>>PBL Peeper (http://www.techno-kitten.com/PreRelease411/setup.exe) does
>>>this, but
>>>it also lets people read PBLs without the PowerBuilder IDE in a much more
>>>readable form than export files. It's been used by people like testers
>>>who
>>>needed to read the code, but didn't have the IDE.
>>>
>>>Good luck,
>>>
>>>Terry and Sequel the techno-kitten
>>>
>>>On 22 Dec 2010 11:31:41 -0800,
>>>in sybase.public.powerbuilder.general
>>>
>>>>We are trying to provide the customer the PowerBuilder
>>>>source code for review. The problem the customer does not
>>>>have a copy of PowerBuilder. Is there any other tool to
>>>>export the source code in a text file without having to
>>>>address each object within PowerBuilder.
>>>*********************************
>>>Build your vocabulary while feeding the hungry
>>>http://www.freerice.com
>>>*********************************
>>>Newsgroup User Manual
>>>=====================
>>>TeamSybase <> Sybase employee
>>>Forums = Peer-to-peer
>>>Forums <> Communication with Sybase
>>>IsNull (AnswerTo (Posting)) can return TRUE
>>>Forums.Moderated = TRUE, so behave or be deleted
>>>*********************************
>>>
>>>Sequel's Sandbox: http://www.techno-kitten.com
>>>Home of PBL Peeper, a free PowerBuilder Developer's Toolkit.
>>>Version 4.0.4 now available at the Sandbox
>>>PB Futures updated June 25/2008
>>>See the PB Troubleshooting & Migration Guides at the Sandbox
>>>^ ^
>>>o o
>>>=*=
>>
>
>
Exporting PowerBuilder Source Code to Text Files 2010-12-22 20:31
Re: Exporting PowerBuilder Source Code to Text... 2010-12-23 20:20
Re: Exporting PowerBuilder Source Code to Text... 2010-12-23 22:52
Re: Exporting PowerBuilder Source Code to Text... 2010-12-24 01:22
Re: Exporting PowerBuilder Source Code to Text... 2010-12-23 17:08
Re: Exporting PowerBuilder Source Code to Text... 2010-12-22 20:53
Re: Exporting PowerBuilder Source Code to Text... 2010-12-22 21:27
Re: Exporting PowerBuilder Source Code to Text... 2010-12-23 10:40
Re: Exporting PowerBuilder Source Code to Text... 2010-12-23 15:05