SlideShare a Scribd company logo
Graphical RPG Framework for IBM i 
SilverDev Tutorial 
Build a Grid and its Popup Menu with the RPG Designer
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 2 / 24 
Steps: 
1. Build a new program ............................................................................................................................. 3 
2. FormCreation ........................................................................................................................................ 6 
3. Database Wizard ................................................................................................................................... 8 
4. Add a Pop-Up menu ............................................................................................................................ 10 
5. Saving and compiling the screen ......................................................................................................... 12 
6. RPG source: Build OnClick Events ....................................................................................................... 13 
7. Additional Tools .................................................................................................................................. 16 
8. Whole source ...................................................................................................................................... 17 
9. Compiling the RPG source ................................................................................................................... 19 
10. Create a CLP program.......................................................................................................................... 20 
11. 1st deployment ................................................................................................................................... 22 
12. Result ................................................................................................................................................... 23
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 3 / 24 
- To follow the steps of this tutorial, you have to install SilverDev on your server. 
- You can download a free 60-day trial on: http://www.silverdev.com/silverdev-free-trial.php 
1. Build a new program 
Launch SilverDev Designer and select a context from the menu Tools> Context.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 4 / 24 
If you have selected the silverdemo option when installing SilverDev, the silverdemo context is diplayed in the list. 
Select it and click the OK button. 
Use the « + » icon to create your new program, in the Context tab :
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 5 / 24 
The program appears on the Context tab. 
Double-click the line to access it 
Source and screen will be displayed on the screen. 
The source file is already filled in.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 6 / 24 
2. Form Creation 
Use the “Components” tool window to add a CSFL type component. 
Select the component from the palette and click the form under construction to place it.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 7 / 24 
Use the “Inspector” tool window to modify the properties of the CSFL component. 
The component must be selected (surrounded by black squares). 
Modify the Align property. Select the alClient value. This means that the component takes up the whole of its parent’s space (here, the form). 
Tip: To obtain help regarding the CSFL component, select the component and press F1 to display the on-line help
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 8 / 24 
3. Database Wizard 
To add columns to the CSFL component, you can double-click the component, but here, we will use a tool to import columns from a database file. 
Use this icon indicated to display the “Database wizard” tab. 
In the “Database wizard” tab, use the search tab. 
Search for the SDDMBKS file (press Enter to start the search). 
The list of corresponding files on the server is displayed. 
Double-click the name of a file to display its characteristics. 
A new window opens: select the IDBOOK, TITLE and PRICE fields (use CTRL to select multiple lines), and drag to the form under construction.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 9 / 24 
Another window opens, asking what you want to do. 
Leave the default selection “Add to grid” and click OK. 
Three columns have been created in the CSFL component. 
The properties of these columns have been modified according to the file’s fields. You can change the properties of these columns if you want.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 10 / 24 
4. Add a Pop-Up menu 
In the “Components” tab, select the CPopupMenu component and place it on the form. 
CpopupMenu is represented by a square. 
Double-click the square to add elements to the popup menu. 
Window “Menu Designer” appears. 
Right click and use the “New” option to create a new menu elements.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 11 / 24 
Use the Property Inspector to change the menu element properties: 
- Call it itemRefresh, with the Name property, 
- Set the Caption property to “Refresh" 
Select the CSFL component again and change its PopupMenu property. Select the PopupMenu1 value. 
This means that when a right click is made on the CSFL component, PopupMenu1 will be displayed.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 12 / 24 
5. Saving and compiling the screen 
On the Form menu, Save and compile the form: 
As you can see below, the screen is a *USRSPC type object:
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 13 / 24 
6. RPG source: Build OnClick Events 
First, we declare SDDMBKS books’ table: 
In the RPGSPCIF block reserved for file declarations, 
declare the SDDMBKS file. 
You can also drag the file name 
from the Database Wizard tab 
To display the ruler, press F8.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 14 / 24 
Now we add the OnClick event to the menu element, itemRefresh. Tip: Press F10 to display the screen. 
Double-click the CPopupMenu component and tick the OnClick event of the itemRefresh element. 
Double click the OnClick line: the cursor is now in the source in the itemRefresh_Onclick event.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 15 / 24 
In the itemRefresh_OnClick event, we will read the sddmbks file 
and fill in the CSFL component: 
In the example, the words shown in purple are functions provided with SilverDev. 
They enable the components to be manipulated via the RPG program. 
To see the list of Silverdev functions, press Ctrl+Space to display the list of functions corresponding to the first letters of the word you are typing in.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 16 / 24 
7. Additional Tools 
Press F2: to display the list of the window’s components and properties in a tree structure 
Press Enter: to insert a component or property name 
Press F4: to see a format prompt window
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 17 / 24 
8. Whole source 
// *===============================================================* 
// * Title . . . : * 
// * Author . .ADUVAL * 
// * Date . . .2014-10-21 * 
// * Project . . : * 
// * Description : * 
// * * 
// * * 
// * -Technical data-----------------------------------------------* 
// * * 
// * Main SDF .*LIBL/TUTO1 * 
// * * 
// *===============================================================* 
*/BLOCK RPGSPCIH 
// -------------- RPGSPCIH : H specifications (Heading) 
*/BLOCK RPGSPCIF 
// -------------- RPGSPCIF : Files declarations (F Spec.) 
FSDDMBKS if e k disk 
*/BLOCK RPGSPCID 
// -------------- RPGSPCID : Data descriptions (D Spec.) 
*/BLOCK RPGSPCII 
// -------------- RPGSPCII : Input descriptions (I Spec.) 
*/BLOCK RPGPARM 
// -------------- RPGPARM : Program parameters and declarations (KLIST, DEFINE, ...) 
*/BLOCK RPGPGMSTART 
// -------------- RPGPGMSTART :Begining of Initializations procedure 
*/BLOCK RPGBEFORECREATE 
// -------------- RPGBEFORECREATE : just before form creation 
*/BLOCK RPGAFTERCREATE 
// -------------- RPGAFTERCREATE : After form creation 
*/BLOCK RPGBEFORESHOW 
// -------------- RPGBEFORESHOW: Before show(F1) 
*/BLOCK RPGAFTERSHOW 
// -------------- RPGAFTERSHOW : After show(F1) 
*/BLOCK RPGPROCDEF
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 18 / 24 
// -------------- RPGPROCDEF : User procedures 
*/BLOCK RPGSR 
// -------------- RPGSR : Sub Routine 
*/BLOCK RPGTABLE 
// -------------- RPGTABLE : Compile time array data (**) 
*/EVENT itemRefresh_OnClick 
‚* --------------------------------------------------------------* 
‚* Description : 
‚* --------------------------------------------------------------* 
D Parameters ds based(pevtinf) 
D Win 5u 0 
D Evt 48a 
‚* 
D row s 10u 0 
ccallpsdClear(F1:'SFL1') 
C *lovalsetllsddmbks 
c read sddmbks 
cdow not %eof(sddmbks) 
ceval row = row + 1 
ccallpsdSetCell(F1:'SFL1':'Title':Row:Title) 
ccallpsdSetCellNum(F1:'SFL1':'Price':Row:price) 
ccallpsdSetCellNum(F1:'SFL1':'idbook':Row:idbook) 
c read sddmbks 
cenddo
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 19 / 24 
9. Compiling the RPG source 
Save the modifications made to the source via the “Members/Save member” menu. 
Compile the program using the “Compilation/Generate program” menu. 
If an error occurs during compilation, a dialog box will be displayed. Click OK. 
The compilation results will be displayed in a new window. Compilation errors are shown in bold. 
Double click a line to access the location in the source. When there are no more errors, the program will be created in SILVERDEMO.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 20 / 24 
10. Create a CLP program 
Now, we are going to create a CL program which will add SILVERDEMO to the library list and run our TUTO1EN program. Write it as usual: 
Or in SilverDev editor: 
Open a New Member in the menu Members 
And write your program: 
Save it in the menu Members/Save Member 
Don’t forget to change the source type in CLP
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 21 / 24 
And compile in the menu Compiling / Create a program:
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 22 / 24 
11. 1st deployment 
To make the application available, you must have administrator rights. Check that your profile is in the SILVERDEV/PSVDADM file. 
Launch MyDesk and right click where you want to make your application available. Then, choose « New application » 
Fill the dialog box with the application title, the file name and the call command. 
On next screen, select the app authorizations.
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 23 / 24 
12. Result 
An icon is now shown in MyDesk: The application is available. 
Double click the icon to start the application that we have just created. Once the application is running, right click on the form and click “Refresh”. 
The grid appears. You can sort it by clicking on the column headers
SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer 
Experia -- Reproduction Rights Reserved -- 24 / 24 
More info on www.silverdev.com 
EXPERIA Europe 
4, rue L.Beridot 
Les jardins d'Epione 
38500 VOIRON - FRANCE 
www.experia.com 
info@experia.com

More Related Content

Similar to [Tutorial] SilverDev Designer - RPG Development Studio

DesignSpark PCB Workshop Notes 2018
DesignSpark PCB Workshop Notes 2018DesignSpark PCB Workshop Notes 2018
DesignSpark PCB Workshop Notes 2018
DesignSparkGC
 
[Tutorial] Insert a Picture in IBM i Applications with SilverDev
[Tutorial] Insert a Picture in IBM i Applications with SilverDev[Tutorial] Insert a Picture in IBM i Applications with SilverDev
[Tutorial] Insert a Picture in IBM i Applications with SilverDev
SilverDev by Experia
 
Getting started with code composer studio v3.3 for tms320 f2812
Getting started with code composer studio v3.3 for tms320 f2812Getting started with code composer studio v3.3 for tms320 f2812
Getting started with code composer studio v3.3 for tms320 f2812
Pantech ProLabs India Pvt Ltd
 
Overview & Downloading the Baseline using Global Configuration Managemen tand...
Overview & Downloading the Baseline using Global Configuration Managemen tand...Overview & Downloading the Baseline using Global Configuration Managemen tand...
Overview & Downloading the Baseline using Global Configuration Managemen tand...
Bharat Malge
 
Getting started with code composer studio v4 for tms320 f2812
Getting started with code composer studio v4 for tms320 f2812Getting started with code composer studio v4 for tms320 f2812
Getting started with code composer studio v4 for tms320 f2812
Pantech ProLabs India Pvt Ltd
 
A d swincc15e
A d swincc15eA d swincc15e
A d swincc15e
confidencial
 
Build your first android mobile app
Build your first android mobile appBuild your first android mobile app
Build your first android mobile app
ekipaco
 
Mobile Worshop Lab guide
Mobile Worshop Lab guideMobile Worshop Lab guide
Mobile Worshop Lab guide
Man Chan
 
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter boardLab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Vincent Claes
 
How to configure an environment to cross-compile applications for beagleboard-xM
How to configure an environment to cross-compile applications for beagleboard-xMHow to configure an environment to cross-compile applications for beagleboard-xM
How to configure an environment to cross-compile applications for beagleboard-xM
Dalton Valadares
 
IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2
IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2
IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2
Tom Schnieders, PhD, A.Eng, AEP
 
Oopp Lab Work
Oopp Lab WorkOopp Lab Work
Oopp Lab Work
Heather Dionne
 
Android Programing Course Material Labs
Android Programing Course Material LabsAndroid Programing Course Material Labs
Android Programing Course Material Labs
Shady Selim
 
generate IP CORES
generate IP CORESgenerate IP CORES
generate IP CORES
guest296013
 
WPF - the future of GUI is near
WPF - the future of GUI is nearWPF - the future of GUI is near
WPF - the future of GUI is near
Bartlomiej Filipek
 
PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...
PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...
PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...
Andrey Karpov
 
Tutorial storybook
Tutorial storybookTutorial storybook
Tutorial storybook
Vinay H G
 
Helm Charts Security 101
Helm Charts Security 101Helm Charts Security 101
Helm Charts Security 101
Deep Datta
 
Analytics with Power BI and R
Analytics with Power BI and RAnalytics with Power BI and R
Analytics with Power BI and R
Naresh R. Jasotani
 
(Manual) auto cad 2000 visual lisp tutorial (autocad)
(Manual) auto cad 2000 visual lisp tutorial (autocad)(Manual) auto cad 2000 visual lisp tutorial (autocad)
(Manual) auto cad 2000 visual lisp tutorial (autocad)
Ketut Swandana
 

Similar to [Tutorial] SilverDev Designer - RPG Development Studio (20)

DesignSpark PCB Workshop Notes 2018
DesignSpark PCB Workshop Notes 2018DesignSpark PCB Workshop Notes 2018
DesignSpark PCB Workshop Notes 2018
 
[Tutorial] Insert a Picture in IBM i Applications with SilverDev
[Tutorial] Insert a Picture in IBM i Applications with SilverDev[Tutorial] Insert a Picture in IBM i Applications with SilverDev
[Tutorial] Insert a Picture in IBM i Applications with SilverDev
 
Getting started with code composer studio v3.3 for tms320 f2812
Getting started with code composer studio v3.3 for tms320 f2812Getting started with code composer studio v3.3 for tms320 f2812
Getting started with code composer studio v3.3 for tms320 f2812
 
Overview & Downloading the Baseline using Global Configuration Managemen tand...
Overview & Downloading the Baseline using Global Configuration Managemen tand...Overview & Downloading the Baseline using Global Configuration Managemen tand...
Overview & Downloading the Baseline using Global Configuration Managemen tand...
 
Getting started with code composer studio v4 for tms320 f2812
Getting started with code composer studio v4 for tms320 f2812Getting started with code composer studio v4 for tms320 f2812
Getting started with code composer studio v4 for tms320 f2812
 
A d swincc15e
A d swincc15eA d swincc15e
A d swincc15e
 
Build your first android mobile app
Build your first android mobile appBuild your first android mobile app
Build your first android mobile app
 
Mobile Worshop Lab guide
Mobile Worshop Lab guideMobile Worshop Lab guide
Mobile Worshop Lab guide
 
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter boardLab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
Lab: Installation of Xilkernel on Xilinx Spartan 3E Starter board
 
How to configure an environment to cross-compile applications for beagleboard-xM
How to configure an environment to cross-compile applications for beagleboard-xMHow to configure an environment to cross-compile applications for beagleboard-xM
How to configure an environment to cross-compile applications for beagleboard-xM
 
IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2
IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2
IMPORTING 3DS MODELS INTO VIRTUAL BATTLESPACE2
 
Oopp Lab Work
Oopp Lab WorkOopp Lab Work
Oopp Lab Work
 
Android Programing Course Material Labs
Android Programing Course Material LabsAndroid Programing Course Material Labs
Android Programing Course Material Labs
 
generate IP CORES
generate IP CORESgenerate IP CORES
generate IP CORES
 
WPF - the future of GUI is near
WPF - the future of GUI is nearWPF - the future of GUI is near
WPF - the future of GUI is near
 
PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...
PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...
PVS-Studio and Continuous Integration: TeamCity. Analysis of the Open RollerC...
 
Tutorial storybook
Tutorial storybookTutorial storybook
Tutorial storybook
 
Helm Charts Security 101
Helm Charts Security 101Helm Charts Security 101
Helm Charts Security 101
 
Analytics with Power BI and R
Analytics with Power BI and RAnalytics with Power BI and R
Analytics with Power BI and R
 
(Manual) auto cad 2000 visual lisp tutorial (autocad)
(Manual) auto cad 2000 visual lisp tutorial (autocad)(Manual) auto cad 2000 visual lisp tutorial (autocad)
(Manual) auto cad 2000 visual lisp tutorial (autocad)
 

More from SilverDev by Experia

[Tutoriel] Créez un graph en RPG avec SilverDev
[Tutoriel] Créez un graph en RPG avec SilverDev[Tutoriel] Créez un graph en RPG avec SilverDev
[Tutoriel] Créez un graph en RPG avec SilverDev
SilverDev by Experia
 
[Tutorial] Crear gráficos en RPG con SilverDev
[Tutorial] Crear gráficos en RPG con SilverDev[Tutorial] Crear gráficos en RPG con SilverDev
[Tutorial] Crear gráficos en RPG con SilverDev
SilverDev by Experia
 
[Tutoriel] Insérer une image dans une application IBM i avec SilverDev
[Tutoriel] Insérer une image dans une application IBM i avec SilverDev[Tutoriel] Insérer une image dans une application IBM i avec SilverDev
[Tutoriel] Insérer une image dans une application IBM i avec SilverDev
SilverDev by Experia
 
[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev
[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev
[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev
SilverDev by Experia
 
[Tutoriel] SilverDev pour IBM i : Démarrage rapide
[Tutoriel] SilverDev pour IBM i : Démarrage rapide[Tutoriel] SilverDev pour IBM i : Démarrage rapide
[Tutoriel] SilverDev pour IBM i : Démarrage rapide
SilverDev by Experia
 
[Tutorial] SilverDev for IBM i: Quick Start
[Tutorial] SilverDev for IBM i: Quick Start[Tutorial] SilverDev for IBM i: Quick Start
[Tutorial] SilverDev for IBM i: Quick Start
SilverDev by Experia
 
Comment simplifier et améliorer l'interfaçage IBM i / PC?
Comment simplifier et améliorer l'interfaçage IBM i / PC?Comment simplifier et améliorer l'interfaçage IBM i / PC?
Comment simplifier et améliorer l'interfaçage IBM i / PC?
SilverDev by Experia
 
How to simplify IBM i / PC exchanges with SilverDev?
How to simplify IBM i / PC exchanges with SilverDev?How to simplify IBM i / PC exchanges with SilverDev?
How to simplify IBM i / PC exchanges with SilverDev?
SilverDev by Experia
 
IBM i: How modernized applications facilitate interactions with PCs?
IBM i: How modernized applications facilitate interactions with PCs? IBM i: How modernized applications facilitate interactions with PCs?
IBM i: How modernized applications facilitate interactions with PCs?
SilverDev by Experia
 
Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)
Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)
Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)
SilverDev by Experia
 
SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...
SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...
SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...
SilverDev by Experia
 
Temoignage SilverDev - Moderniser l’existant en RPG avec SilverDev
Temoignage SilverDev - Moderniser l’existant en RPG avec SilverDevTemoignage SilverDev - Moderniser l’existant en RPG avec SilverDev
Temoignage SilverDev - Moderniser l’existant en RPG avec SilverDev
SilverDev by Experia
 
[Tutoriel] Studio de développement RPG SilverDev Designer
[Tutoriel] Studio de développement RPG SilverDev Designer[Tutoriel] Studio de développement RPG SilverDev Designer
[Tutoriel] Studio de développement RPG SilverDev Designer
SilverDev by Experia
 

More from SilverDev by Experia (13)

[Tutoriel] Créez un graph en RPG avec SilverDev
[Tutoriel] Créez un graph en RPG avec SilverDev[Tutoriel] Créez un graph en RPG avec SilverDev
[Tutoriel] Créez un graph en RPG avec SilverDev
 
[Tutorial] Crear gráficos en RPG con SilverDev
[Tutorial] Crear gráficos en RPG con SilverDev[Tutorial] Crear gráficos en RPG con SilverDev
[Tutorial] Crear gráficos en RPG con SilverDev
 
[Tutoriel] Insérer une image dans une application IBM i avec SilverDev
[Tutoriel] Insérer une image dans une application IBM i avec SilverDev[Tutoriel] Insérer une image dans une application IBM i avec SilverDev
[Tutoriel] Insérer une image dans une application IBM i avec SilverDev
 
[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev
[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev
[Tutorial] Insertar una imagen en una aplicación IBM i con SilverDev
 
[Tutoriel] SilverDev pour IBM i : Démarrage rapide
[Tutoriel] SilverDev pour IBM i : Démarrage rapide[Tutoriel] SilverDev pour IBM i : Démarrage rapide
[Tutoriel] SilverDev pour IBM i : Démarrage rapide
 
[Tutorial] SilverDev for IBM i: Quick Start
[Tutorial] SilverDev for IBM i: Quick Start[Tutorial] SilverDev for IBM i: Quick Start
[Tutorial] SilverDev for IBM i: Quick Start
 
Comment simplifier et améliorer l'interfaçage IBM i / PC?
Comment simplifier et améliorer l'interfaçage IBM i / PC?Comment simplifier et améliorer l'interfaçage IBM i / PC?
Comment simplifier et améliorer l'interfaçage IBM i / PC?
 
How to simplify IBM i / PC exchanges with SilverDev?
How to simplify IBM i / PC exchanges with SilverDev?How to simplify IBM i / PC exchanges with SilverDev?
How to simplify IBM i / PC exchanges with SilverDev?
 
IBM i: How modernized applications facilitate interactions with PCs?
IBM i: How modernized applications facilitate interactions with PCs? IBM i: How modernized applications facilitate interactions with PCs?
IBM i: How modernized applications facilitate interactions with PCs?
 
Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)
Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)
Témoignage Igloo Post-Mix (Orangina-Schweppes / Pepsi Cola)
 
SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...
SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...
SilverDev / ARCAD Skipper Interface - for Structured Graphic Developments in ...
 
Temoignage SilverDev - Moderniser l’existant en RPG avec SilverDev
Temoignage SilverDev - Moderniser l’existant en RPG avec SilverDevTemoignage SilverDev - Moderniser l’existant en RPG avec SilverDev
Temoignage SilverDev - Moderniser l’existant en RPG avec SilverDev
 
[Tutoriel] Studio de développement RPG SilverDev Designer
[Tutoriel] Studio de développement RPG SilverDev Designer[Tutoriel] Studio de développement RPG SilverDev Designer
[Tutoriel] Studio de développement RPG SilverDev Designer
 

Recently uploaded

Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Malak Abu Hammad
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
IndexBug
 
UI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentationUI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentation
Wouter Lemaire
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
How to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptxHow to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptx
danishmna97
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Alpen-Adria-Universität
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
saastr
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
Skybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoptionSkybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoption
Tatiana Kojar
 
Choosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptxChoosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptx
Brandon Minnick, MBA
 
5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides
DanBrown980551
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
MichaelKnudsen27
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
Daiki Mogmet Ito
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
Mariano Tinti
 
Taking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdfTaking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdf
ssuserfac0301
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
DianaGray10
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
Octavian Nadolu
 
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfHow to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
Chart Kalyan
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 

Recently uploaded (20)

Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
 
UI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentationUI5 Controls simplified - UI5con2024 presentation
UI5 Controls simplified - UI5con2024 presentation
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
How to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptxHow to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptx
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
Skybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoptionSkybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoption
 
Choosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptxChoosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptx
 
5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
 
Taking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdfTaking AI to the Next Level in Manufacturing.pdf
Taking AI to the Next Level in Manufacturing.pdf
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
 
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfHow to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 

[Tutorial] SilverDev Designer - RPG Development Studio

  • 1. Graphical RPG Framework for IBM i SilverDev Tutorial Build a Grid and its Popup Menu with the RPG Designer
  • 2. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 2 / 24 Steps: 1. Build a new program ............................................................................................................................. 3 2. FormCreation ........................................................................................................................................ 6 3. Database Wizard ................................................................................................................................... 8 4. Add a Pop-Up menu ............................................................................................................................ 10 5. Saving and compiling the screen ......................................................................................................... 12 6. RPG source: Build OnClick Events ....................................................................................................... 13 7. Additional Tools .................................................................................................................................. 16 8. Whole source ...................................................................................................................................... 17 9. Compiling the RPG source ................................................................................................................... 19 10. Create a CLP program.......................................................................................................................... 20 11. 1st deployment ................................................................................................................................... 22 12. Result ................................................................................................................................................... 23
  • 3. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 3 / 24 - To follow the steps of this tutorial, you have to install SilverDev on your server. - You can download a free 60-day trial on: http://www.silverdev.com/silverdev-free-trial.php 1. Build a new program Launch SilverDev Designer and select a context from the menu Tools> Context.
  • 4. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 4 / 24 If you have selected the silverdemo option when installing SilverDev, the silverdemo context is diplayed in the list. Select it and click the OK button. Use the « + » icon to create your new program, in the Context tab :
  • 5. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 5 / 24 The program appears on the Context tab. Double-click the line to access it Source and screen will be displayed on the screen. The source file is already filled in.
  • 6. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 6 / 24 2. Form Creation Use the “Components” tool window to add a CSFL type component. Select the component from the palette and click the form under construction to place it.
  • 7. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 7 / 24 Use the “Inspector” tool window to modify the properties of the CSFL component. The component must be selected (surrounded by black squares). Modify the Align property. Select the alClient value. This means that the component takes up the whole of its parent’s space (here, the form). Tip: To obtain help regarding the CSFL component, select the component and press F1 to display the on-line help
  • 8. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 8 / 24 3. Database Wizard To add columns to the CSFL component, you can double-click the component, but here, we will use a tool to import columns from a database file. Use this icon indicated to display the “Database wizard” tab. In the “Database wizard” tab, use the search tab. Search for the SDDMBKS file (press Enter to start the search). The list of corresponding files on the server is displayed. Double-click the name of a file to display its characteristics. A new window opens: select the IDBOOK, TITLE and PRICE fields (use CTRL to select multiple lines), and drag to the form under construction.
  • 9. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 9 / 24 Another window opens, asking what you want to do. Leave the default selection “Add to grid” and click OK. Three columns have been created in the CSFL component. The properties of these columns have been modified according to the file’s fields. You can change the properties of these columns if you want.
  • 10. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 10 / 24 4. Add a Pop-Up menu In the “Components” tab, select the CPopupMenu component and place it on the form. CpopupMenu is represented by a square. Double-click the square to add elements to the popup menu. Window “Menu Designer” appears. Right click and use the “New” option to create a new menu elements.
  • 11. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 11 / 24 Use the Property Inspector to change the menu element properties: - Call it itemRefresh, with the Name property, - Set the Caption property to “Refresh" Select the CSFL component again and change its PopupMenu property. Select the PopupMenu1 value. This means that when a right click is made on the CSFL component, PopupMenu1 will be displayed.
  • 12. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 12 / 24 5. Saving and compiling the screen On the Form menu, Save and compile the form: As you can see below, the screen is a *USRSPC type object:
  • 13. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 13 / 24 6. RPG source: Build OnClick Events First, we declare SDDMBKS books’ table: In the RPGSPCIF block reserved for file declarations, declare the SDDMBKS file. You can also drag the file name from the Database Wizard tab To display the ruler, press F8.
  • 14. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 14 / 24 Now we add the OnClick event to the menu element, itemRefresh. Tip: Press F10 to display the screen. Double-click the CPopupMenu component and tick the OnClick event of the itemRefresh element. Double click the OnClick line: the cursor is now in the source in the itemRefresh_Onclick event.
  • 15. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 15 / 24 In the itemRefresh_OnClick event, we will read the sddmbks file and fill in the CSFL component: In the example, the words shown in purple are functions provided with SilverDev. They enable the components to be manipulated via the RPG program. To see the list of Silverdev functions, press Ctrl+Space to display the list of functions corresponding to the first letters of the word you are typing in.
  • 16. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 16 / 24 7. Additional Tools Press F2: to display the list of the window’s components and properties in a tree structure Press Enter: to insert a component or property name Press F4: to see a format prompt window
  • 17. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 17 / 24 8. Whole source // *===============================================================* // * Title . . . : * // * Author . .ADUVAL * // * Date . . .2014-10-21 * // * Project . . : * // * Description : * // * * // * * // * -Technical data-----------------------------------------------* // * * // * Main SDF .*LIBL/TUTO1 * // * * // *===============================================================* */BLOCK RPGSPCIH // -------------- RPGSPCIH : H specifications (Heading) */BLOCK RPGSPCIF // -------------- RPGSPCIF : Files declarations (F Spec.) FSDDMBKS if e k disk */BLOCK RPGSPCID // -------------- RPGSPCID : Data descriptions (D Spec.) */BLOCK RPGSPCII // -------------- RPGSPCII : Input descriptions (I Spec.) */BLOCK RPGPARM // -------------- RPGPARM : Program parameters and declarations (KLIST, DEFINE, ...) */BLOCK RPGPGMSTART // -------------- RPGPGMSTART :Begining of Initializations procedure */BLOCK RPGBEFORECREATE // -------------- RPGBEFORECREATE : just before form creation */BLOCK RPGAFTERCREATE // -------------- RPGAFTERCREATE : After form creation */BLOCK RPGBEFORESHOW // -------------- RPGBEFORESHOW: Before show(F1) */BLOCK RPGAFTERSHOW // -------------- RPGAFTERSHOW : After show(F1) */BLOCK RPGPROCDEF
  • 18. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 18 / 24 // -------------- RPGPROCDEF : User procedures */BLOCK RPGSR // -------------- RPGSR : Sub Routine */BLOCK RPGTABLE // -------------- RPGTABLE : Compile time array data (**) */EVENT itemRefresh_OnClick ‚* --------------------------------------------------------------* ‚* Description : ‚* --------------------------------------------------------------* D Parameters ds based(pevtinf) D Win 5u 0 D Evt 48a ‚* D row s 10u 0 ccallpsdClear(F1:'SFL1') C *lovalsetllsddmbks c read sddmbks cdow not %eof(sddmbks) ceval row = row + 1 ccallpsdSetCell(F1:'SFL1':'Title':Row:Title) ccallpsdSetCellNum(F1:'SFL1':'Price':Row:price) ccallpsdSetCellNum(F1:'SFL1':'idbook':Row:idbook) c read sddmbks cenddo
  • 19. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 19 / 24 9. Compiling the RPG source Save the modifications made to the source via the “Members/Save member” menu. Compile the program using the “Compilation/Generate program” menu. If an error occurs during compilation, a dialog box will be displayed. Click OK. The compilation results will be displayed in a new window. Compilation errors are shown in bold. Double click a line to access the location in the source. When there are no more errors, the program will be created in SILVERDEMO.
  • 20. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 20 / 24 10. Create a CLP program Now, we are going to create a CL program which will add SILVERDEMO to the library list and run our TUTO1EN program. Write it as usual: Or in SilverDev editor: Open a New Member in the menu Members And write your program: Save it in the menu Members/Save Member Don’t forget to change the source type in CLP
  • 21. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 21 / 24 And compile in the menu Compiling / Create a program:
  • 22. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 22 / 24 11. 1st deployment To make the application available, you must have administrator rights. Check that your profile is in the SILVERDEV/PSVDADM file. Launch MyDesk and right click where you want to make your application available. Then, choose « New application » Fill the dialog box with the application title, the file name and the call command. On next screen, select the app authorizations.
  • 23. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 23 / 24 12. Result An icon is now shown in MyDesk: The application is available. Double click the icon to start the application that we have just created. Once the application is running, right click on the form and click “Refresh”. The grid appears. You can sort it by clicking on the column headers
  • 24. SilverDev Tutorial – Build a Grid and its Popup Menu with the RPG Designer Experia -- Reproduction Rights Reserved -- 24 / 24 More info on www.silverdev.com EXPERIA Europe 4, rue L.Beridot Les jardins d'Epione 38500 VOIRON - FRANCE www.experia.com info@experia.com