HR - dynamic selections field name and field value in the program
HI all,
I am using dynamic selections for a HR report.
I have created a view with 20 fields and added it to HR report category ___00003(All fields suppressed).
I need to check these fields in the program. But i am not able to get the field name and value in the program for dynamic selections fields.
Please let me know how to get the field names and values in the program for dynamic selections .
Thanks,
Kranthi.
You have to read the itab <i>pnpdynse</i> in your Program to obtain the Dynamic Selection values. This itab has a deep structure.. you can set a break point in one of the events before <b>get pernr</b> & in the debug mode, you will able to display the itab <i>pnpdynse</i>.. you can then identify how to get the values into your code..
~Suresh
Similar Messages
-
BAPI Structure populating using field name and field value frm internal tbl
Hi Experts,
Need your help, my requirement is to populate BAPI import structure using its field name and filed value stored in a internal table. Please advise the best approach.
Regards
Ram.Hi, in an ABAP program you can make use of FIELD-SYMBOLS and the ASSIGN statement for filling the BAPI fields based on the fieldname found in the internal table. Hopes it answer your question. Succes
-
How to put the column name and variable value in the alert message.
Dear,
how can i put the column name and variable value in the alert message text. i want to display an alert which tell the user about the empty textboxes. that these textboxes must be filled.
Regards:
Muhammad Nadeem
CHIMERA PVT. LTD.
LAHORE
[email protected]Hello,
The name of the item that fires the current trigger is stored in the :SYSTEM.TRIGGER_ITEM system variable.
The value contained in this item can be retrived with the Name_In() built-in
value := Name_In( 'SYSTEM.TRIGGER_ITEM') ;
LC$Msg := 'The item ' || :SYSTEM.TRIGGER_ITEM || ' must be entered' ;
Set_Alert_Property('my_alert_box', ALERT_MESSAGE_TEXT, LC$Msg ) ;
Ok := Show_Alert( 'my_alert_box' ) ;
...Francois -
Fields names and fields labels
Hello everybody!!
I would like to know if there is a way to know the name of a field in a dynpro knowing its description.
Eg:
I know the field label _(description)--> vendor, and I want to guess the field name (lifnr)
thank you very much!Hi,
You can check the table DD04T...to get the data element for the corresponding text..
Is this what you want??
If you want to know in debugging..I believe it is not possible to get the field name for the field description..
Thanks
Naren -
Dynamically assigning field name and field value
Hi all,
logic:
select field1 field2 from table into workarea.
workarea-field1 will have value as 'MATNR' or 'BUKRS' or 'KUNNR' or............etc
workarea-field1 will have values as '10000025' or '2010' or '102536' or ............etc
Now i need to dynamically assign MATNR = 10000025
or BUKRS =2010
or KUNNR = 102536
HOW CAN WE DO THIS.Hi,
Use the ASSIGN COMPONENT statement.
Regards,
Ankur Parab -
Using a dialog window to select a name and directory to save the file
Hi there
I have a problem with the FILE_SAVE_DIALOG method or better with the windows that will be shown.
Before I save a file (e.g. PDF file) on the presentation server (the PC), I want to open a dialog window to have the option to give another directory and file name, under which I will save the file.
Therefore I use the method CL_GUI_FRONTEND_SERVICES=>FILE_SAVE_DIALOG. I found many information about this FILE_SAVE_DIALOG in this forum, but these tips didn't satisfy me.
The main problem is the FILE_FILTER. How to use this filter (is it a STRING?) properly, when I want to have a list in the dialog window? Nothing worked till now.
I use ERP 2005 with JAVA 1.4.1-07.
My Code:
DATA: fileName TYPE STRING,
path TYPE STRING,
workdir TYPE STRING,
user_action TYPE I,
encoding TYPE ABAP_ENCODING.
fileName = I_FILENAME.
path = I_PATH.
CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_SAVE_DIALOG
EXPORTING
WINDOW_TITLE = 'Save Adobe PDF file'
* WITH_ENCODING = 'X'
INITIAL_DIRECTORY = workdir
* DEFAULT_EXTENSION = '*.pdf'
DEFAULT_FILE_NAME = fileName
FILE_FILTER = '*.pdf'
PROMPT_ON_OVERWRITE = 'X'
CHANGING
FILENAME = fileName
PATH = path
FULLPATH = fullpath
USER_ACTION = user_action
FILE_ENCODING = encoding
EXCEPTIONS
CNTL_ERROR = 1
ERROR_NO_GUI = 2
NOT_SUPPORTED_BY_GUI = 3
others = 4.
IF SY-SUBRC <> 0.
EXIT.
ENDIF.
IF user_action <> CL_GUI_FRONTEND_SERVICES=>ACTION_OK.
EXIT.
ENDIF.
When I call this method with these parameters, I get the dialog window, but there is no filtering for PDFs.
I also tried the ideas with:
FILE_FILTER = 'Adobe files (*.pdf)|(*.pdf)'
and so on. But nothing made the dialog window work properly, even the selection list didn't show the right content to select.
Who can help with this method SAVE_FILE_DIALOG?
Thanks
FrowinHI,
check this program.
<b>
report ZTEST2.
data: file type string,
path type string,
file_path type string.
data: itab type standard table of cskt.
start-of-selection.
SELECT * FROM cskt INTO TABLE itab.
call method cl_gui_frontend_services=>file_save_dialog
exporting
FILE_FILTER = '*.PDF'
changing FILENAME = file
path = path
fullpath = file_path.
check not file_path is initial.
call method cl_gui_frontend_services=>gui_download
exporting filename = file_Path
WRITE_FIELD_SEPARATOR = 'X'
changing data_tab = itab.
</b>
REgards, -
Which table stores field names and their description?
When I go to se11; I can get information about a table; its field names and field description.
How can I access same information using an ABP Program? I have a third party tool which connects to SAP; it can pull data from any SAP Table or view. I do not know which table or view stores information displayed in SE11.
Thanks a lot.Hi zigzagdna,
The field names and their description are strored in table DD03L and DD03T.
SAP DDIC dictionary informations are generally store in DD* tables. You can search this kinds of DD* tables in SE11 using F4 search help.
With Best Regards
Julia -
Query parameters with the same name and different values
According to HTTP, multiple query or post parameters with the
same name and different values are permitted. They are transfered
over the wire in the following format -
name1=val1&name1=val2&name1=val3
The problem is that I can't see anyway of assigning multiple
parameters with the same name and different values to the request
object of mx.rpc.http.HTTPService. I have tried using the
flash.utils.Dictionary object as it does strict key comparison but
that doesn't work too. I have tried setting an array of values to a
property of the request object but that sends the request to the
server in the following format -
name1=val1,val2,val3
The java servlet engines throw exceptions when they see this.
Any help would be greatly appreciated.If you're not on 8.1.4 move there. 8.1.3 had limitations in the wsrp
release.
wrote:
I have an html select box that contains several values, and multiple
selection is enabled. When my code runs as a remote portlet, the
following is showing up in the soap monitor when I select multiple
values and submit the form:
<urn:interactionParams>
<urn:portletStateChange>cloneBeforeWrite</urn:portletStateChange>
<urn:interactionState>_action=addEmployeesToGroup</urn:interactionState>
<urn:formParameters
name="P62005wlw-select_key:{actionForm.selectedEmployees}OldValue">
<urn:value>true</urn:value>
</urn:formParameters>
<urn:formParameters
name="P62005wlw-select_key:{actionForm.selectedEmployees}">
<urn:value>beatest1</urn:value>
</urn:formParameters>
In this case, I selected beatest1 and beatest2, but only beatest1 comes
through to the remote portlet. Is this a known bug, and, if so, is
there a patch or workaround available?
Thanks in advance,
Andy -
Srvrmgr syntax: how can I create Named Subsystem with both Name and Description values?
In looking through bookshelf, there is no syntax discussed that allows you to include both the Name value and the Description value for a Named Subsystem/Profile Configuration. In the screenshot, the circled values were created with the server manager command-line.
In contrast, you can create a component definition with a Name (full name) and Description.
For CompDef, this works:
create component definition CompDefTest1_enu for component type AppObjMgr component group Fins run mode Interactive full name "Test Comp Def Test 1" description "Test 1 Object Manager CompDef"
For Named Subsytem, this does NOT work:
create named subsystem Test5 for subsystem EAITransportDataHandlingSubsys full name "Test 5" description 'Test 5 Description'
Can anyone tell me if, for a Named Subsytem, there is a proper syntax to include both the Name and Description values in the command-line, or is the only way to manually create it in the UI?Hi,
I have reviewed the help for create command in srvrmgr, it does not give the full name and description as parameters for subsystem creation. However, as you indicated these parameters are available for component definition creation:
srvrmgr> help create
create { component group | compgrp } <component group name>
[ full name <descriptive name> ]
[ { description | desc } <description of component group> ]
create { component definition | compdef } <component definition name>
for { component type | comptype } <component type name>
{ component group | compgrp } <component group name>
run mode { batch | interactive | background }
[ full name <descriptive name> ]
[ { description | desc } <description of component definition> ]
[ with [param <param_name>=<value>[, <param_name>=<value>...]]
[fixparam <fixed_param_name>=<fixed_value>[,...]]]
create named subsystem <named_subsystem_name> for
subsystem <subsystem_name> with <param_name>=<param_value> [, ..]
Bookshelf also has an example of subsystem creation that does not include full name and description:
http://docs.oracle.com/cd/E14004_01/books/StoreFwdMsg/StoreFwdMsg_InstallConfig14.html#wp1351472
In this case I suggest you to create a ticket on My Oracle Support to confirm that srvrmgr does not support creating a new subsystem with full name and description parameters, and request an enhancement request for these parameters to be included in create statement for new subsystems when using srvrmgr.
Hope it helps,
WSiebel -
Flat file should have source field name and value
Hi Friends
I have a scenario of Idoc to Flat file , where in the target structure the field name and value should be present, generally only the value is available in a flat file.The target structure is as below:
for e.g RECTYPE is the Field Name and A is the value.
RECTYPE,A
DATEH,20111101
TIMEH,173125
RECTYPE,B
ORDNUM,4500054536
ORDITM,150
SUPDAT,20090218
PLNQTY,000000006
MATNR,14B300
BATCH,5697
PLANT,3026
DELIVTYPE,PO
SUPPLIER,0000023305
SUPNAME,Deutsche BP AG
SUPADRS,Erkelenzer Strasse 20
SUPCITY,Monchengladbach
SUPPOST,41179
SUPCOUN,DE
TRUCK_NBR,7589
BOND_FLG,X
STG_LOC,PLCL
LINE_ACTION,CRE
RECTYPE,B
ORDNUM,4500056721
ORDITM,10
SUPDAT,20090218
PLNQTY,000000013
MATNR,116703
BATCH,6589
PLANT,3026
DELIVTYPE,PO
SUPPLIER,0000023380
SUPNAME,DOW Belgium NV
SUPADRS,Havenlaan 7
SUPCITY,Tessenderlo
SUPPOST,3980
SUPCOUN,BE
TRUCK_NBR,7589
BOND_FLG,X
STG_LOC,PLCL
LINE_ACTION,CHG
RECTYPE,X
DATEH,20111101
TIMEH,173125
RECORDS,3Hi,
NameA.addHeaderLine
Specify whether the text file will have a header line with column names. The following values are permitted:
■ 0 u2013 No header line
■ 1 u2013 Header line with column names from the XML document
■ 2 u2013 As for 1, followed by a blank line
■ 3 u2013 Header line is stored as NameA.headerLine in the configuration and is applied
■ 4 u2013 As for 3, followed by a blank line
This specification is only permitted if exactly one structure is defined.
regards,
ganesh. -
How to get the class name and field name dynamically
Hi
I have a class (ex: Contract) the fields (ex : a,b,c) .i need to get the class name and field name dynamically
ex
if( validation file for the field Contract.a){
return contract.a;
}else if(validation file for the field Contract.b){
return contract.b;
how to pass the field name and object dynamically
Please help me .............
Thanks in Advance..
Edited by: 849614 on Aug 11, 2011 6:49 AMYoungWinston wrote:
maheshguruswamy wrote:
Agreed, but IMO, i still feel its best if there is no tie in between consumer class level details and the database it talks to. A service layer is needed in between them.Sounds like you've done a bit of this before. Me, I've either been a modeller/DBA, doling out data, or a nuts and bolts programmer (and actually more toolmaker than apps, but did a bit of that too).
Do you know of a good book about the "middle ground" (ie, these service layers)? I understand it empirically, but haven't had a lot of exposure to it.
Winston
Edited by: YoungWinston on Aug 11, 2011 10:34 PM
PS: Apologies. Edited my previous post, presumably while you were composing your reply, when I finally realized what '.filed' meant.Most of my work is in web development, never been a DBA :) . The biggest 'concern' in my shop is 'separation of concerns'. The UI group reports up to a different IT head, the DB group reports up to a different IT head and so on. The looser the coupling between these systems, the lesser the project costs (Integration, QA etc) are. Martin Fowler's books contain good information about separation of concerns in an enterprise environment. The two books which i recommend are
[url http://www.amazon.com/Patterns-Enterprise-Application-Architecture-Martin/dp/0321127420]Enterprise Application Architecture and
[url http://www.amazon.com/Enterprise-Integration-Patterns-Designing-Deploying/dp/0321200683/ref=pd_sim_b_1]Enterprise Integration Patterns -
What is table name and field name for balance value in sales order in sap
hi i want to make FS for sales order status report .and i want balance value in report please tell me about table field name of balance value.
You can get the Sales Order status in Table VBUK & VBUP at Item Level.
To achieve the Open Value , first consider the Open Quantity.Refer VBAP - KWMENG (Order Quantity) , then from LIPS - LFIMG (Delivery Quantity) , you will get the Open Quantity & then accordingly you will get the open Value.
Best Regards,
Ankur -
hi frds
Give me table name and field name of OPEN PO QUANTITY ..
thanks
Pari Vendhan.RSee the sample code for the open PO's based on Vendor
and do accordingly
*& Report ZMM_PO_REPORT
REPORT ZMM_PO_REPORT message-Id yb
NO STANDARD PAGE HEADING
LINE-COUNT 60(1)
LINE-SIZE 230.
D A T A B A S E T A B L E S D E C L A R A T I O N
TABLES: lfa1, " Vendor Master
t161, " PO Doc Types
t024, " Purchase Groups
ekko. " PO Header
T Y P E S D E C L A R A T I O N S
Purchase Orders Main Structure
TYPES: BEGIN OF s_po,
ebeln TYPE ebeln, " PO No.
ebelp TYPE ebelp, " PO Item
bstyp TYPE bstyp, " PO Category
bukrs TYPE bukrs, " Company Code
bsart TYPE bbsrt, " PO Type
lifnr TYPE lifnr, " Vendor No
ekgrp TYPE bkgrp, " Purchase Group
waers TYPE waers, " Currency
bedat TYPE etbdt, " PO Date
txz01 TYPE txz01, " Material Text
werks TYPE ewerk, " Plant
lgort TYPE lgort_d, " Storage Location
matkl TYPE matkl, " Material Group
menge TYPE bamng, " PR Quantity
meins TYPE bamei, " UOM
bprme TYPE bbprm, " Price Unit
netpr TYPE netpr, " Net price
peinh TYPE peinh, " Price Unit UOM
pstyp TYPE pstyp, " Item Category
knttp TYPE knttp, " Account Assignment Category
END OF s_po.
Purchase Orders History Structure
TYPES: BEGIN OF s_account,
ebeln TYPE ebeln, " PO No.
ebelp TYPE ebelp, " PO Item
gjahr TYPE mjahr, " Fiscal Year
belnr TYPE mblnr, " PO Invoice No
menge TYPE menge_d, " PR Quantity
wrbtr TYPE wrbtr, " Price in Local Currency
dmbtr TYPE dmbtr, " Price in Foreign Currency
waers TYPE waers, " Currency
shkzg TYPE shkzg, " Dr/Cr Indicator
END OF s_account.
Purchase Orders History Structure(Item Sum)
TYPES: BEGIN OF s_inv_sum,
ebeln TYPE ebeln, " PO No.
ebelp TYPE ebelp, " PO Item
menge TYPE menge_d, " PR Quantity
wrbtr TYPE wrbtr, " Price in Foreign Currency
waers TYPE waers, " Currency
END OF s_inv_sum.
Purchase Orders Main Structure
TYPES: BEGIN OF s_rep,
lifnr TYPE lifnr, " Vendor No
ebeln TYPE ebeln, " PO No.
ebelp TYPE ebelp, " PO Item
bstyp TYPE bstyp, " PO Category
bsart TYPE bbsrt, " PO Type
ekgrp TYPE bkgrp, " Purchase Group
waers TYPE waers, " Currency
bedat TYPE etbdt, " PO Date
txz01 TYPE txz01, " Material Text
werks TYPE ewerk, " Plant
lgort TYPE lgort_d, " Storage Location
matkl TYPE matkl, " Material Group
menge TYPE bamng, " PR Quantity
meins TYPE bamei, " UOM
bprme TYPE bbprm, " Price Unit
netpr TYPE netpr, " Net price
peinh TYPE peinh, " Price Unit UOM
pstyp TYPE pstyp, " Item Category
knttp TYPE knttp, " Account Assignment Category
name1 TYPE name1, " Plant
orewr TYPE netpr, " To be Invoiced Price
curr TYPE waers, " Inv Doc Currency
END OF s_rep.
D A T A D E C L A R A T I O N S
DATA: gv_title1 TYPE sylisel, " Report title
gv_dial. " Color flag
C O N S T A N T S D E C L A R A T I O N S
CONSTANTS: c_x VALUE 'X', " Flag X
c_h VALUE 'H', " Debit
c_vgabe TYPE vgabe VALUE '2'. " Transaction Type
I N T E R N A L T A B L E S D E C L A R A T I O N S
DATA: i_po TYPE STANDARD TABLE OF s_po WITH HEADER LINE,
" Purchase Order
i_inv TYPE STANDARD TABLE OF s_inv_sum WITH HEADER LINE,
" PO Invoice Values
i_rep TYPE STANDARD TABLE OF s_rep WITH HEADER LINE,
" PO Invoice Values
i_ekbe TYPE STANDARD TABLE OF s_account WITH HEADER LINE.
" PO Invoice Values
S E L E C T I O N S C R E E N *
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
SELECT-OPTIONS: s_lifnr FOR lfa1-lifnr MATCHCODE OBJECT kred,
s_ebeln FOR ekko-ebeln MATCHCODE OBJECT mekk,
s_bsart FOR t161-bsart,
s_ekgrp FOR t024-ekgrp,
s_bedat FOR ekko-bedat.
SELECTION-SCREEN END OF BLOCK b1.
I N I T I A L I Z A T I O N *
INITIALIZATION.
A T S E L E C T I O N - S C R E E N *
AT SELECTION-SCREEN.
Validate the screen fields
PERFORM validate_screen.
S T A R T - O F - S E L E C T I O N *
START-OF-SELECTION.
Fetch main data
PERFORM fetch_data.
T O P - O F - P A G E *
TOP-OF-PAGE.
Header of the List
PERFORM header.
E N D - O F - P A G E *
Footer
END-OF-PAGE.
ULINE.
E N D - O F - S E L E C T I O N *
END-OF-SELECTION.
Display the Report Output data
PERFORM display_data.
At Line-Selection
AT LINE-SELECTION.
When double clicked on EBELN display the details of Purchase Doc
PERFORM line_sel.
*& Form validate_screen
Validation of Selection Screen fields
FORM validate_screen .
Validation of Vendor Number
CLEAR lfa1-lifnr.
IF NOT s_lifnr[] IS INITIAL.
SELECT lifnr UP TO 1 ROWS
INTO lfa1-lifnr
FROM lfa1
WHERE lifnr IN s_lifnr.
ENDSELECT.
IF sy-subrc 0.
MESSAGE e000 WITH 'Invalid Vendor'(002).
ENDIF.
ENDIF.
Validation of PO Number
CLEAR ekko-ebeln.
IF NOT s_ebeln[] IS INITIAL.
SELECT ebeln UP TO 1 ROWS
INTO ekko-ebeln
FROM ekko
WHERE ebeln IN s_ebeln.
ENDSELECT.
IF sy-subrc 0.
MESSAGE e000 WITH 'Invalid Document Number'(003).
ENDIF.
ENDIF.
Validation of PO Document Type
CLEAR t161-bsart.
IF NOT s_bsart[] IS INITIAL.
SELECT bsart UP TO 1 ROWS
INTO t161-bsart
FROM t161
WHERE bsart IN s_bsart.
ENDSELECT.
IF sy-subrc 0.
MESSAGE e000 WITH 'Invalid Purchase Document Type'(004).
ENDIF.
ENDIF.
Validation of Purchasing Group
CLEAR t024-ekgrp.
IF NOT s_ekgrp[] IS INITIAL.
SELECT ekgrp UP TO 1 ROWS
INTO t024-ekgrp
FROM t024
WHERE ekgrp IN s_ekgrp.
ENDSELECT.
IF sy-subrc 0.
MESSAGE e000 WITH 'Invalid Purchasing Group'(005).
ENDIF.
ENDIF.
ENDFORM. " validate_screen
*& Form fetch_data
Fetching the PO related data from Database Tables
FORM fetch_data .
CLEAR i_po.
REFRESH i_po.
SELECT a~ebeln " PO No.
b~ebelp " PO Item
a~bstyp " PO Category
a~bukrs " Company Code
a~bsart " PO Type
a~lifnr " Vendor No
a~ekgrp " Purchase Group
a~waers " Currency
a~bedat " PO Date
b~txz01 " Material Text
b~werks " Plant
b~lgort " Storage Location
b~matkl " Material Group
b~menge " PR Quantity
b~meins " UOM
b~bprme " Price Unit
b~netpr " Net price
b~peinh " Price Unit UOM
b~pstyp " Item Category
b~knttp " Account Assignment Category
INTO TABLE i_po
FROM ekko AS a JOIN ekpo AS b
ON a~ebeln = b~ebeln
WHERE a~ebeln IN s_ebeln AND
a~lifnr IN s_lifnr AND
a~ekgrp IN s_ekgrp AND
a~bsart IN s_bsart AND
a~bedat IN s_bedat.
SORT i_po BY ebeln ebelp.
break-point.
IF NOT i_po[] IS INITIAL.
Fetch the PO History/Invoice Details from EKBE Table
CLEAR i_ekbe.
REFRESH i_ekbe.
SELECT ebeln " PO No.
ebelp " PO Item
gjahr " Fiscal Year
belnr " PO Invoice No
menge " PR Quantity
wrbtr " Price in Local Currency
dmbtr " Price in Foreign Currency
waers " Currency
shkzg " Dr/Cr Indicator
INTO TABLE i_ekbe
FROM ekbe
FOR ALL ENTRIES IN i_po
WHERE ebeln = i_po-ebeln AND
ebelp = i_po-ebelp AND
vgabe = c_vgabe.
IF sy-subrc = 0.
SORT i_ekbe BY ebeln ebelp.
LOOP AT i_ekbe.
IF i_ekbe-shkzg = c_h.
i_ekbe-wrbtr = i_ekbe-wrbtr * -1.
ENDIF.
MODIFY i_ekbe.
ENDLOOP.
break-point.
Sum up the Item wise Invoice totals
LOOP AT i_ekbe.
AT END OF ebelp.
READ TABLE i_ekbe INDEX sy-tabix.
SUM.
MOVE-CORRESPONDING i_ekbe TO i_inv.
APPEND i_inv.
ENDAT.
CLEAR i_inv.
ENDLOOP.
SORT i_inv BY ebeln ebelp.
break-point.
ENDIF.
ENDIF.
Move the Vendor Name and Invoice Values to I_rep Internal Table
LOOP AT i_po.
MOVE-CORRESPONDING i_po TO i_rep.
CLEAR i_inv.
READ TABLE i_inv WITH KEY ebeln = i_po-ebeln
ebelp = i_po-ebelp.
IF sy-subrc = 0.
i_rep-orewr = ( i_po-menge - i_inv-menge ) * i_po-netpr.
i_rep-curr = i_inv-waers.
ELSE.
i_rep-orewr = i_po-menge * i_po-netpr.
i_rep-curr = i_po-waers.
ENDIF.
break-point.
Get the Vendor Name
CLEAR lfa1-name1.
SELECT SINGLE name1 FROM lfa1 INTO lfa1-name1
WHERE lifnr = i_po-lifnr.
IF sy-subrc = 0.
i_rep-name1 = lfa1-name1.
ENDIF.
APPEND i_rep.
CLEAR i_rep.
break-point.
ENDLOOP.
SORT i_rep BY lifnr ebeln ebelp.
DELETE i_rep WHERE orewr LE 0.
break-point.
ENDFORM. " fetch_data
*& Form display_data
Display the Report Output data
FORM display_data .
DATA: lv_flag, " New Flag
lv_rec TYPE i. " No of Records
CLEAR lv_rec.
IF i_rep[] IS INITIAL.
MESSAGE e000 WITH 'No Data found'(022).
ELSE.
LOOP AT i_rep.
Toggle Color
PERFORM toggle_color.
IF lv_flag space.
NEW-LINE.
ENDIF.
At New Purchase Document
AT NEW ebeln.
WRITE:/1 sy-vline, 2(10) i_rep-ebeln INTENSIFIED OFF.
lv_flag = c_x.
lv_rec = lv_rec + 1.
ENDAT.
WRITE: 1 sy-vline,
12 sy-vline,13(4) i_rep-bsart,
17 sy-vline,18(10) i_rep-lifnr,
28 sy-vline,29(35) i_rep-name1,
64 sy-vline,65(4) i_rep-ekgrp,
69 sy-vline,70(10) i_rep-bedat,
80 sy-vline,81(5) i_rep-ebelp,
86 sy-vline,87(40) i_rep-txz01,
127 sy-vline,128(9) i_rep-matkl,
137 sy-vline,138(1) i_rep-pstyp,
139 sy-vline,140(1) i_rep-knttp,
141 sy-vline,142(4) i_rep-werks,
146 sy-vline,147(4) i_rep-lgort,
151 sy-vline,152(13) i_rep-menge UNIT i_rep-meins,
165 sy-vline,166(3) i_rep-meins,
169 sy-vline,170(15) i_rep-netpr CURRENCY i_rep-waers,
185 sy-vline,186(4) i_rep-waers,
190 sy-vline,191(5) i_rep-peinh,
196 sy-vline,197(4) i_rep-bprme,
201 sy-vline,202(15) i_rep-orewr CURRENCY i_rep-curr,
217 sy-vline,218(4) i_rep-curr,
222 sy-vline,223(7) i_rep-bstyp centered,
230 sy-vline.
NEW-LINE.
hide: i_rep-ebeln.
ENDLOOP.
ULINE.
FORMAT COLOR OFF.
WRITE : /2 'Total Number of Purchasing Documents:'(025) COLOR 3,
lv_rec COLOR 3.
ENDIF.
ENDFORM. " display_data
*& Form header
Write the Report Header
FORM header .
FORMAT RESET.
header
WRITE:/1(230) 'LIST OF PURCHASE DOCUMENTS PER VENDOR'(006) CENTERED.
SKIP.
FORMAT COLOR COL_HEADING.
ULINE.
WRITE:/1 sy-vline,2(10) 'Pur.Doc.No'(006) CENTERED,
12 sy-vline,13(4) 'Type'(007),
17 sy-vline,18(10) 'Vendor'(008) CENTERED,
28 sy-vline,29(35) 'Name'(009) CENTERED,
64 sy-vline,65(4) 'PGrp'(010) CENTERED,
69 sy-vline,70(10) 'Doc.Date'(012) CENTERED,
80 sy-vline,81(5) 'Item'(011),
86 sy-vline,87(40) 'Material Short Text'(024) CENTERED,
127 sy-vline,128(9) 'Mat.Group'(013),
137 sy-vline,138(1) 'I',
139 sy-vline,140(1) 'A',
141 sy-vline,142(4) 'Plnt'(014),
146 sy-vline,147(4) 'SLoc'(015),
151 sy-vline,152(13) 'Quantity'(016) CENTERED,
165 sy-vline,166(3) 'UoM'(017),
169 sy-vline,170(15) 'Net Value'(018) CENTERED,
185 sy-vline,186(4) 'Curr'(019),
190 sy-vline,191(5) 'Per'(020),
196 sy-vline,197(4) 'Unit'(021),
201 sy-vline,202(15) 'To be Invoiced'(023) CENTERED,
217 sy-vline,218(4) 'Curr'(019),
222 sy-vline,223(7) 'Doc.Cat'(026),
230 sy-vline.
ULINE.
ENDFORM. " header
*& Form toggle_color
This routine alters the color of the records in the list FORM toggle_color.
IF gv_dial = space.
FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
gv_dial = c_x.
ELSE.
FORMAT COLOR 1 INTENSIFIED OFF.
CLEAR gv_dial.
ENDIF.
ENDFORM. " toggle_color
*& Form LINE_SEL
*When double clicked on EBELN field display the details of Purchase Doc
FORM line_sel.
CASE sy-lsind.
WHEN '1'.
DATA: lv_field(20),
lv_value(10),
lv_bstyp like i_rep-bstyp.
clear: lv_bstyp,lv_value, lv_field.
GET CURSOR FIELD lv_field VALUE lv_value.
IF lv_field = 'I_REP-EBELN'.
IF NOT lv_value IS INITIAL.
READ LINE sy-index FIELD VALUE i_rep-bstyp
INTO lv_bstyp.
READ CURRENT LINE FIELD VALUE i_rep-bstyp INTO lv_bstyp.
if lv_bstyp = 'F'.
SET PARAMETER ID 'BES' FIELD lv_value.
CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN.
elseif ( lv_bstyp = 'K' or lv_bstyp = 'L' ).
SET PARAMETER ID 'VRT' FIELD lv_value.
CALL TRANSACTION 'ME33' AND SKIP FIRST SCREEN.
elseif lv_bstyp = 'A'.
SET PARAMETER ID 'ANF' FIELD lv_value.
CALL TRANSACTION 'ME43' AND SKIP FIRST SCREEN.
endif.
ENDIF.
ENDIF.
ENDCASE.
ENDFORM. " line_sel{code]
<REMOVED BY MODERATOR>
kushagra
Edited by: Alvaro Tejada Galindo on Feb 18, 2008 2:03 PM -
Hi All,
I got some output values from the legacy system with me but need to know whats the actual field name and table name to which i need to transfer these values. How can i do it, since which theres is not field name or despcription given for the data.
Is there any way i can do it.
Points will be rewarded for all useful answers.
Regards
ABif you know the transaction code you use to post the uploaded data in SAP, you just need to do BDC recording in using transation SM35. Record the whole process and create a program from the recording... and you wont even need to know the tables and field names-- almost everything will be done for you....
All you need to do is replace record data with upload data.
You can also try to look for a standard Function Module / BAPI which can do the processing for you and provide it with a table containing the upload data ...
Reward points if useful -
Field names with now values behind are written to RDI-File?
Dear experts,
I have a question concerning the RDI file format.
The specification of RDI file said the following about the structure of each RDI file
"field name" is placed in position : 104
"field length" indicator is placed in position : 235 - 237
"field value" is placed in position : 241 Specified by u2018field length indicatoru2019
In addition I got the information, that even if there is no field value for a specific field name. That the field name and also the length of the field will be displayed in the RDI file.
Now I generated an RDI file and I see that only these field (name, position, value) are displayed in RDI which have a value. Fields which contains no value are not displayed!
In conclusion, my first question would be if its correct that field names and also the lengths are everys time displayed in RDI even if there is no value for it?
If this is true, the second question would be: Whatr could be the reason that the field names are not in the RDI file when there is no value for it.
Thanks in advance for any helpful answersDear experts,
I have a question concerning the RDI file format.
The specification of RDI file said the following about the structure of each RDI file
"field name" is placed in position : 104
"field length" indicator is placed in position : 235 - 237
"field value" is placed in position : 241 Specified by u2018field length indicatoru2019
In addition I got the information, that even if there is no field value for a specific field name. That the field name and also the length of the field will be displayed in the RDI file.
Now I generated an RDI file and I see that only these field (name, position, value) are displayed in RDI which have a value. Fields which contains no value are not displayed!
In conclusion, my first question would be if its correct that field names and also the lengths are everys time displayed in RDI even if there is no value for it?
If this is true, the second question would be: Whatr could be the reason that the field names are not in the RDI file when there is no value for it.
Thanks in advance for any helpful answers
Maybe you are looking for
-
DST iCal bug (at least for Sony Ericsson mobiles)
The recent Daylight Savings changes caused a baffling bug to show itself. I keep my phone's calendar (Sony Ericsson K610i) synchronised with my iCal calendar. This includes my timetable for the academic term, with about 13 weekly recurring events. As
-
Source Material error when burning disk image
Well, I've been haunting these forums for 10 days, finding answers to every darn problem under the sun I've encountered! (thanks folks, I've been near hysteria) Now I have yet another problem, and I cannot find an answer in the forums (sorry if it's
-
Automatic Creation of Employee Vendor record when hired in HR
Hi Gurus, Any assistance in Automatic creation of Employee vendor record when the employee is hired in HR master data. Thanks in Advance BLITZZ
-
AMFPHP hanging in browser but not Flash IDE?
Wrote a service that sends a bytearray to my Flash app that works perfectly fine when I test it in the Flash IDE (CS5), and when I compile the app and run it in a browser directly from my computer. When I load it on to the server to run in my browser
-
Dreamweaver and Fireworks Webdesign
I can across this website, www.alphagraphicdesigns.com. They have over 100 different styles to chose from for fireworks to use in Dreamweaver and the pack that you can buy comes with components for flash as well. I definitly recomend this site to any