Documente Academic
Documente Profesional
Documente Cultură
GetStarted
Solutions Support Training Community Developer Partner
About
AStepbyStepguideto
createasimpleFPM
applicationusingFeeder
ClassforFORMGUIBB
December2,2012 | 4,758Views |
RahulMahajan
morebythisauthor
UIFloorplanManagerforWebDynproABAP
share
0 share
0 tweet share
0 0
like
Follow
Introduction:
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 1/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
Inthisarticle,wewillcreateasimpleFPMApplicationusingFEEDERCLASS
for FORM GUIBB (Generic User Interface Building Blocks). We will use OIF
(ObjectInstanceFloorplan)inthisarticle.
We will take a simple example of getting the material number from user and
displaying the description of it using FORM GUIBB. One needs to follow all
thestepstoavoidtheruntimeerrors.
WhatisFeederClass?
AclassthatimplementstheIF_FPM_GUIBB_FORMABAPinterface(forform
components) or the IF_FPM_GUIBB_LIST ABAP interface (for list
components). Business logic can be access through it. It is the link between
theapplicationandtheGUIBB.
There are 2 ways which can be used to develop the FPM application. One is
using Free Style UIBB and Generic UIBB. In this article we will use the
GUIBB(FORMisoneoftheavailableGUIBB).
Stepstobefollowed:
1.GototransactioncodeSE24andcreateaFEEDERClassasfollows.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 2/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
2)GototheInterfacestabandentertheinterfaceforFORMGUIBB
IF_FPM_GUIBB_FORM.
AndpressEnter.ItwillautomaticallyaddtheinterfaceforthegenericUIBB
IF_FPM_GUIBB
3)NowifyouclickontheMethodstab,youwillseeallthemethods
implementedbythesetwointerfaces.MakeSureyougoinsideeachand
everyMethodandactivatethemsoitwontgiveshortdump.
4)Now,gotomethodGET_DEFINITIONenterthefollowingcode.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 3/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
*ThismethodisforbuildingFieldcatalogandactionsrequiredintheform
*LocalVaribaledeclarations
DATA:li_action_lineTYPEfpmgb_s_actiondef.
*PrepareFieldcatalog
eo_field_catalog?=cl_abap_tabledescr=>describe_by_name(MAKT).
Herewecanuseanyflatstruturesorlocaltypes
*Prepareactions
li_action_lineid=GET_MAT.Youcangivewahtevernameyou
wanttotheactionID
li_action_linevisible=cl_wd_uielement=>e_visiblevisible.
li_action_lineenabled=abap_true.
li_action_lineimagesrc=ICON_ADDRESS.Image
foractions
APPENDli_action_lineTOet_action_definition.
5)GotomethodGET_DATAenterthefollowingcode.
DATA:li_makt_lineTYPEmakt.
li_makt_line=cs_data.cs_datacontainsthedata
IFli_makt_linematnrISNOTINITIAL.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 4/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
ev_data_changed=abap_true.
ENDIF.
*CheckiftheStartOverButtoninclickedIfyesclearthecontents
ifio_event>MV_EVENT_ID=FPM_GOTO_START.
CLEARcs_data.
ENDIF.
REMOVEDsteps6,7and8
9)CreatetheWebDynproApplicationbyrightclickingoncomponentas
follows.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 5/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
Component:FPM_OIF_COMPONENT
Interfaceview:FPM_WINDOW
11)NowgotothepackagewhereyouhavesavedtheWebDynproApplication
andrightclickontheApplicationandclickCreate/ChangeConfiguration.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 6/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
12)Itwillopenthebrowser.EntertheConfigurationID.ThisistheFIRST
CONFIGURATIONofyourFPMapplication.ThisiscalledasAPPLICATION
CONFIGURATION.PressEntersoitwillgivethefollowingERROR.
ThisisexpectedbecausetillthispointyourAPPLICATION
CONFIGURATIONdoesnotexist.ClickonCreatebutton.Youwill
receivethesuccessmessage.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 7/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
Thisisagainexpectederrorandsameasabove(Step12).Clickon
Createandgiveyourpackageanditwillopenthenextscreenwiththe
successmessage.
14)ClickontheAttributesbuttonandenterComponentas
FPM_FORM_UIBB.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 8/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
Nowasmentionedintheinformationalmessageonscreen,gotoView
andclickonF4helpandselecttheViewasFORM_WINDOW.
ClickOK
15)NowletscreatetheGUIBBConfigurationandhenceenterthe
ConfigurationNameandclickEnter.ItwillappearabovetheConfigureUIBB
button.
16)Youwillreceivethesameerrorandthatisexpectederror.ClickonCreate.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 9/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
17)EnteryourpackagenameandthenitwillaskfortheFEEDERCLASS
name.EntertheFeederClassnameandclickonEditParameters.
18)Youwillreceivethewarningmessageandthatcanbeignored.
JustclickOK.
19)Onthisscreen,ClickontheAddGroup.Itwilladdthegroup1underForm
andyoucannameit.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 10/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
20)Afteraddinggroup,weneedtoconfigurethatasfollows.Selectthe
MATNRaswewanttodisplayitasInputfieldandthenaddButtonRow.
ClickOK.
21)FromEnhancementpack5,wehavesomeverygoodoptionslikeValue
Suggestionwhileenteringthematerialnumber.Inordertoviewalltheoptions
availablejustclickontheElement:MateriallinkunderFORM>Group1.
22)Afterthatletsconfigurethebuttonwehaveaddedandaddtheactiontoit.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 11/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
23)Todisplaythematerialdetails,letsaddonemoregroupandconfigureitby
selectingthefieldswewanttodisplayasfollows.
24)Clickontheindividualelementsandsetthepropertyasfollows:
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 12/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
DoitforallthefieldsandclickonSAVE.
25)Finally,TESTtheapplication.Thereare2waystotesttheapplicationas
follows.
a)ClickontheApplicationConfigurationlinkandthenclickonTEST.
aa
ItwilltakeyoutotheApplicationConfiguration.JustclickonTEST.
b)FromSE80enteryourpackagenameandselecttheapplicationandclick
onApplicationConfigurationandexecute.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 13/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
26)TheResultscreenlookslikeasfollows,Enterthematerialandtheclickon
GetDetailsitwillpopulatethedata.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 14/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
AlertModerator
18Comments
PratoshKumar
April15,2013at6:26pm
goodexplain..veryhelpfultounderstandfeederclass
RahulMahajan Postauthor
June11,2013at7:12am
ThanksPratosh!
girishkumar
May10,2013at3:09pm
GreateffortRahul,youhavemadeitsimple,thanksforsharing!!!
Cheers,
Girish
RahulMahajan Postauthor
June11,2013at7:13am
ThanksGirish!
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 15/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
PraveenKumar
June24,2013at5:00pm
Thankyou:)
VRV
June26,2013at9:37pm
ThanksRahul
Itisagooddocument.
MattHarding
July10,2013at2:19am
HiRahul,
Nicetutorial,thoughImnotsurewhyyoudidsteps6,7and8asitappearsyou
starttocreateaWebDynproComponentthatimplementsaUIBBthatisthen
notusedintherestofthetutorialandyouthencreateaWebDynpro
ApplicationthatdoesntpointatyournewUIBB.
AmImissingsomething?
Cheers,
Matt
ChristopherLinke
July11,2013at9:50am
Ialsodontseetheneedforthis
RahulMahajan Postauthor
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 16/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
July15,2013at5:31am
HiMatt/Christopher,
Youarecorrect.Inthiscase,wedontneedtocreateWD
Component.Ihaveremovedthosesteps.
Regardingusageofwdapplication,iamattaching
FPM_OIF_COMPONENTasacomponent.
Appreciateyourfeedback.
Thanks,
Rahul
PeterDornheim
August15,2013at9:51am
Hello,
Ithinkitiseasy,butIdontknowwhattodowiththis
line:
DATA:li_makt_lineTYPEmakt.
Igettheerror:TYPEMAKTISUNKNOWNWhatis
therighttype?
Thanks
Peter
RahulMahajan Postauthor
August15,2013at10:13am
HiPeter,
DATA:li_makt_lineTYPEmakt.
Withthisline,wearedeclaringthework
areaoftypeMAKT.
Ifyoujustcopyandpastethecodein
GET_DATAmethodmentionedabove,it
shouldwork.
Pleaseletmeknowwhatcodeyouhave
writtenandgettingthaterror.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 17/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
Thanks,
Rahul
PeterDornheim
August15,2013at10:26am
Theproblemis,thattable
MAKTisnotavailableinmy
System.ItsNetWEaver7.31
RahulMahajan Postauthor
August15,2013at11:03am
Okay,Inthatcasepleaseuse
availabletype.
HappyLearning!
NishantBansal
February25,2014at10:49am
ThanksRahulforsharing.
Thanks.
NishantBansal
VenkataNagaChaitanyaBhatlapenumarthi
March4,2014at8:55pm
ThanksRahul.
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 18/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
ArshadAnsary
March16,2014at5:42am
HiRahul
Thanksfortheexample.
ButideallyyoushouldbeusingIF_FPM_GUIBB_FORM~PROCESS_EVENT
methodof
feederclasstoprocesseventGET_MAT.
MydoubtishowdowepasseventparameterstothePROCESS_EVENT.
Foregiwanttopassmatnraloneasimportingparametertotheeventhandler
method.WiththaMATNRiwilfindtheMAKTandsetthedatawithinEvent
hahdler
Regards
Arshad
GhadeerZahaiqa
August7,2014at5:14pm
HiRahul
Thanksforexample
IhaveproblemthatidonthaveconfiguregroupbuttoninGUIBBcomponentconfiguration
evenifiopenSAPdemoindisplaymodeitsnotappear
couldyoupleaseadviceme.
liketheshootbelow:
zaminicharak
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 19/20
2017511 AStepbyStepguidetocreateasimpleFPMapplicationusingFeederClassforFORMGUIBB|SAPBlogs
March13,2015at1:48pm
HiRahul,
Iamnotabletoconfigurebuttonrow.Pleasehelp.
AddComment
https://blogs.sap.com/2012/12/02/astepbystepguidetocreateasimplefpmapplicationusingfeederclassforformguibb/ 20/20