Set Value in a ME22N's field with user exit.
Every time an PO is create in ME21N or ME22N I need that the user to input some valid Requisitioner in PO's item. These valid Requisitioners are in a Z table.
Well, to solve this I've used the EXIT_SAPMM06E_017 exit. I call the function F4IF_INT_TABLE_VALUE_REQUEST but it is not bringing the requisitioner I've selected to the field in ME22N the field remains empty.
data : i_usr like zmmwfnfusr occurs 0 with header line,
wa_usr like DDSHRETVAL occurs 0 with header line.
IF i_ekpo-afnam IS INITIAL. "The field resquisitioner
MESSAGE s079(z1) WITH 'Requerente obrigatório para Workflow'
'Receb. de NFs.'
'Digite um Setor Recebedor cadastrado!'.
v_repid = sy-repid.
v_dynnr = sy-dynnr.
select * "My table with requisitioners
from zmmwfnfusr
into table i_usr.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'RECEBEDOR' "Field name of zmmwfnfusr
DYNPPROG = v_repid
DYNPNR = v_dynnr
DYNPROFIELD = 'TEKPO-AFNAM' "Tried to guess
the field name, tried all namens..
VALUE_ORG = 'S'
TABLES
value_tab = i_usr
return_tab = wa_usr.
Hi,
try with this
process on value-request.
field AFANAM module onvalue_request_afanam.
and check what is the field name in the screen which you want to populate the value like (materail) Material is the Dynpro field and MATNR is the retfield
in the module
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'LIFNR' <data element for afanam>
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'AFANAM'
value_org = 'S'
tables
value_tab = itab
return_tab = ret_tab
FIELD_TAB = FIELD_TAB
exceptions
parameter_error = 1
no_values_found = 2
others = 3.
this should work,
Cheers,
Sasi
Similar Messages
-
MRP Run with User Exit key for Follow up material
Dear Gurus,
I want to run MRP only for followup materials by using User exit key. For example i have a material X(with discontinued Indicator as 1) and it's follow material is Y.
So we have a user exit key as ZFL, with coding as shown below. Now when i run MD01 with user exit key ZFL and parametre as 1, it only runs MRP for material X and not for material Y. What else we need to do so that when i run MD01 with user exit key ZFL, it shoudl consider both X and Y.
WHEN 'ZFL'.
DATA : BEGIN OF ITAB5 OCCURS 0,
KZAUS LIKE MT61D-KZAUS,
END OF ITAB5.
TRANSLATE USER_PAR TO UPPER CASE.
SPLIT USER_PAR AT ',' INTO TABLE ITAB5.
IF ITAB5[] IS INITIAL.
EXIT.
ENDIF.
CLEAR: NO_PLANNING, STOP_PLANNING.
READ TABLE ITAB5 WITH KEY KZAUS = MT61D-KZAUS.
IF SY-SUBRC <> 0.
NO_PLANNING = 'X'.
ENDIF.Hi Kumar,
You can use either MRP Type, MRP Controller, MRP Group in this user exit to control the MRP run. For these set of Materials you have to assign any of same value or at least differentiate these material from other material. Then only you can control the MRP by using this user exit even though if you use different MRP Group and MRP Controller. In User Exit, you may have to add your dependent material's MRP Group/MRP Controller. Make sure that these set of materials are different than all other materials.
If you don't have any plan to run MRP for other materials then as per Ajit suggestion you make that material's MRP type as "ND". But, in your business case they may want to activate the MRP for all the material not now but may be latter.
Thanks -
BPS Attribute as Variable filled with User-Exit
Hello,
how is it possible to set a variable from the type "attribute" in BPS with an User-Exit?
Example: Characteristic = Material, Attribute = Material class
How can I set valid entries for Material class in a User-Exit?
Thanks for help in advance
EckhardEckhard,
You can solve this by using characteristic relationship type exit. there you can put a function where you can find the values for the attribute material class.
greets,
Jeroen -
Please help me with user-exits or baids for TCode : FOE2 & FOE1
Hi Experts
Please help me with user-exits or baids for TCode : FOE2 & FOE1.
I found these but not picking values from VIMI01,VIOB03 and VIOB41.
User-exits
FVCH0001 CH-specific enhancements: Esp. POR
ISRE0001 Determine bank procedure account no.
ISRE0002 IPD reporting data retrieval
Business Add-in
FVD_HANDLE_FORMULA Processing of Condition FormulasHi,
ASk your basis regarding the CI_CSKB table active issue, and first of all i dont see any table with the name CI_CSKB.
And check this exit-COOMKS03 whether it works for your screen exits.
Cheers!!
VEnk@
Edited by: Venkat Reddy on Nov 4, 2008 5:59 PM -
Issue with user exit ZXPADU01 and ZXPADU02
Hi,
I am trying to change the existing record for the info type 0015 for an employee in Pa30 transaction.
my requirement is i need old value and new value when i am changing the existing record in info type 0015.
When i kept break point in user exit ZXPADU01 it is not triggering it is triggering only when we creating the record.
i tried with user exit ZXPADU02 it is not working as per my requirement.
My requirement is :whenever i am changing the existing record(modifying record) i need old value and new value.
Anybody can suggest me how to fix this issue.
Thanks,
MaheedharDear Maheedhar,
The best way to achieve this requirement is to use the PAI user exit ZXPADU02 import parameter PSAVE. The PSAVE parameter contains the PBO original / initial record, before any changes take place.
The INNNN parameter contains the current PAI record as usual, in order to be used for customer check and new values. Thus, you've got both the old and the new record in place, and you can make your comparison according to the business requirements: -
Formula variable with User Exit
Hi,
Can we create a Formula Variable of processing type USER EXIT...which will display a constant Value Y
Any syntax would be helpful
ThanksHi,
check this for formula variables with user exits;
http://wiki.sdn.sap.com/wiki/display/profile/Surendra+Reddy
http://sap.ittoolbox.com/groups/technical-functional/sap-bw/customer-exit-to-derive-formula-variable-to-text-variable-sap-bw-35-3030684
Also Check the issues and solution :
Formula Variable with User Exit....Problem
Thanks
Hemav -
Difference between the different structures while dealing with User-Exits
While dealing with User-Exits, we come across the different structures/Tables like XVBAP,YVBAP,TVBAP,IVBAP,*VBAP....
What is the difference between them ?Usually X<tablename> and Y<tablename> are used in change document management to determine records updated (Y is old values and X new ones). (Look at transaction SCDO)
T<tablename is an internal table read from database and I<tablename> is an import table parameter of the same structure. <tablename> is an equivalent of <tablename> declared with statement TABLES and contains usually the "old" value.
Look at exit documentation. start at [User Exits In Sales Document Processing|http://help.sap.com/saphelp_46c/helpdata/en/1c/f62c7dd435d1118b3f0060b03ca329/content.htm]
Regards -
Valuation price with user exit/BADI/Enhancement Spot (In valuation variant)
Hi all,
i am facing problem finding enhancement when creation of sales order of Valuation price with user exit/BADI/Enhancement Spot (In valuation variant)
For refferenece:
When going to t.code VA03, select one item and go to extras in the menu bar and select costing then you find some amounts calculation i.e valuation price automatically.
So when creation of sales order i am giving material and that material price automatically takes from material master and creating sales order.
My customer requirement is to get the valuation price of the input material from Z-table during the sales order cost estimate.
This Z-table contains the material code, plant , grade of the material.
Ex:
Material Plant Grade Price
A 1000 XYZ 25000
A 1000 PQR 35000
A 1000 BCD 45000
Suppose it depends on sales document type and which grade price i have to take.
So first of all i am unable to find enhancement where to change this code to get change the valuation price.
Does anybody have any idea , is there any user exit/BADI/enhancement for this.
So please help me in this issue.
Thanks & Regards,
lokeshgoudpls allow me to post the questions
-
Valuation price with user Exit on activity types
Hi All,
Our customer could have different activity cost for different products even if they are processed on the same cost center, same activity type and same activity time. So I wonder whether SAP has valuation price with user Exit on activity types as what on material valuation, when we select "U" in the relevant valuation variant. Could anyone knows advise please?
Regards
WalterHi Walter,
an idea might be to include an ABC template into the costing. ABC tempaltes allow a big degree of freedom in determinin which processes to use and in which quantities. To use the product as a cost driver is certainly not an issue. I doubt that you can directly influence the process 'price' to be applied, but to change the quantity could bring the same result.
See the docu for more info:
[http://help.sap.com/saphelp_erp60_sp/helpdata/en/7e/cb7d1443a311d189ee0000e81ddfac/frameset.htm]
best regards,
Udo -
Setting value in the detail level field using hdr level lov
i try to set value in the detail table using hdr LOV , at that time some fields value are set and some are not set. i don't understand why this happens, please give me the solution
huh?
You provide nowhere near enough information for us to even understand what you want to do, let alone to answer.
John -
How to automatically set value of sold to party field in crmd_order screen?
Hi Experts,
We have a requirement where we have to automatically populate a standard SAP screen field when the screen opens. The T-code is crmd_order and the field is present in the fast entry tab whenu201Dcreate support messageu2019 is clicked. Now I am trying to achieve this by implementing the BADI which this T code calls. There are no user exits to this as per my understanding. There are some 20 BADIs this Tcode calls before opening. I have tried implementing almost all of them but the value is not getting reflected on the screen field. List of BADIu2019s called are as below.
We are trying to automatically populate the sold to party field based upon the guid of the support message. Based upon this guid of the support message we are fetching list of partner function from u201CBAPI_ACTIVITYCRM_GETDETAILMULTu201D. Then we are taking the partner function value of u201CSLFN0002u201D. The BP number captured from this partner function will be passed to u201CBAPI_BUPA_ADDRESS_GETDETAILu201D to get the country of the super user. Based on this country the sold to party is to be determined.
We have made a Z table for fetching this sold to party/region based on the country derived from above logic:
Z Table
Country Region/Customer/sold to party
IN IN/BAN-C1
BD IN/BAN-C2
US US/CAN-C1
Now these unique (sold to party/region) values based on the country has to be populated automatically on the sold to party field of the screen (CRMD_ORDER).
The logic for deriving the same is correct and the main problem is to default it on the screen field.After getting the value of the required field I am trying to display it on the screen by using the standard FM u201CCRM_ORDER_MAINTAINu201D and passing the value in IT_PARTNER.The FM is getting executed but the value is not getting reflected on the screen. I donu2019t understand where it is going wrong I am not able to solve this.Kindly let me know if anyone can throw some light on this.
Regds,
vlpHi vlp,
You can achive it with BAdI:CRM_ORDER_FIELDCHECK. Actually I've implemented the similar case with this BAdI. This BAdI is called many times because it always works when any field is changed. So you should restrict the timing your logic works.
Regards,
Masayuki -
Hi Frds,
I am updating the Order Status from Workflow. So the Status update (or Order Changed) is save with Workflow ID. I need to insert UserID instead of workflow ID. Please help me out of this.
Thanks
ImranHi Imran
With the very few details available on your process, the workflow design and the "Order", all I can suggest is that:
1) In your workflow definition, go to the step which sends the user decision, in the binding FROM the TASK TO the Workflow, set _ACTUAL_AGENT to a workflow container element , say DECISION_AGENT (of type SWHACTOR)
2) Assuming that the next step in APPROVAL branch is setting of the status, go the task ID of that Step -> make it a dialog step (remove the Background Processing check) -> set it's agent assignment to general task
3) Back in the workflow, set that STATUS SETTING step to Advance With Dialog under the details tab
4) In the control tab of the same step, in the agents section, set agent as EXPRESSION and the value as &DECISION_AGENT&
When a user approves the decision item, his ID will be stored in DECISION_AGENT
The status set will execute immediately (because of "Advance with Dialog") in the same session of approving as the user who approved is the same running this step now
The status will be set by the ID of the Approver
The above is hypothetical considering
1) You do not have dynamic parallel processing
2) Status setting happens immediately after the approval; as a first step in the approval branch
3) The Decision Task does not has "Confirm End of Processing" checked.
Regards,
Modak -
Missing column value when logged on to windows with user id other then admi
I am using crystal report 10 with oracle 10g database. Application is is developed on vissual studio.net 2005 (vb.net). Reports are launched from vb.net application.
My report runs fine when I logon to windows as administrator and launch vb.net application. When I logeed on to windows with userid other then administrator my application works fine except one of the column value is missing a value in the report. When I launch my vb.net application my oracle userid is same. Only difference is windows userid. My application has no referance to windows userid. Why crystal report viewer is missing one column value when loged on to windows as user(xxxx)?CR 10.2 bundles with .NET 2005. If you do not see the CR assemblies of version 10.2.3600 in GAC, try to do a custom install of .net 2005, choosing just Crystal Reports. Note that Crystal Reports does not bundle with all versions of .NET (for example it does not ship with .NET Express - I believe...). Alternatively, you can upgrade to CR 2008 which is the latest sipping version of Crystal Reports. You can obtain a copy by calling sales at 866-681-3435, or go to this link:
www.businessobjects.com/product/catalog/crystalreports
An eval copy of CR 2008 can be downloaded from here:
http://www.businessobjects.com/forms/default.asp?id=701600000009BXP
Ludek -
Numeric value variable problem with user exit
Dear experts,
I've created a variable (numeric value, user exit) and I want to get the value of variable from an user exit.
Actually, I want to convert "0calyear" to a number to be albe to calculate (multiplying, dividing etc).
If there is a possible solution only in FOX, the solution will be the best. However I couldn't find anything.
So, the next solution I am trying is user-exit. But I am in stuck here.
The problem is that I have no idea whether the numeric value variable has any sturcture like other variables(char. value) or not. If yes, what structure it has?
I know, the characterisc value variables have the structure as blow,
ls_varsel-chanm =
ls_varsel-seqno =
ls_varsel-sign =
ls_varsel-opt =
ls_varsel-low =
I've tried several times with the same way like above, but it doesn't work when I call the variable in "BPS0" or "UPSPL".
How can I solve it? Please let me know.
I am using SEM_BW 4.00.
Many Thanks.
BruceHi Ravi,
Sorry, there's a correction. <b>var2 is used for getting the first month of the year selected by the user in var1</b>. If the user doesn't enter a value for var1, then var2 should take first month of current year from var1 which has by default last month of current year (populated in i_step1 from sy-datum). The user can select the value of var1 according to his requirement. Then var 2 should get first month of the year selected. That's why I'm using two exit variables.
It works fine during the initial run of the query. But when the user clicks on the variable button in the toolbar and executes the query, var1 is not being displayed and an error message <i>No value could be determined for var2</i> is shown. All other variables used in the query are displayed except var1.
Krzys, Is the option <i>Can be changed in Query Navigation</i> available for Exit variables. I'll check that and get back to you.
Boujema, Thanks for the OSS note.
Thanks
Hari -
How to retrieve the value of field in user exit EXIT_SAPMF(in the include)
Hello All,
I am using user exit EXIT_SAPMF02K_001 for limiting the user to input the PAN number upto 10 character and first 4 character should be alphanumeric.I have done the logice and its running fine. The problem i am facing is that i could not get the screen input in the include where i have written the code ie. i am not able to get the screen field when the user exit is executed .In short i m not getting the value of the field ie(J_1IMOVEND-J_1IPANNO) in the code which i have written in the include.
Can you pls tell me how do i get the value of the field PAN in the code . I have debug the program and it doesnot show any value.
Reply ASAP.
Thanks in Adv.
Pravesh DeshbhratarHi ,
The Transaction code used is FK02.
Secondly when i am using the debugger the i m getting into the INCLUDE Of the User Exit EXIT_SAPMF02K_001.
So i dont think i am using incorrect user exit.
what is required is field value in the include of EXIT_SAPMFO2K_001.
Thanks
Pravesh
Maybe you are looking for
-
Link Item Style to open a PDF hangs if opened in IE in 30 seconds
Hi, I am using Jdeveloper version 9.0.3. I have a page in which, I have an advanced table, in which there is a column, with item style - link. On the link item there is a PPR event and it should open a PDF file, residing on the server. I am using jav
-
ORA-12519 TNS:No appropriate service handler found!
Dear All, I am facing a strange problem since yesterday and it happened for 4 times now. My database is 10gR2 and Linux is the operating system. There is not much load on DB but some users while connecting to DB get this error: ORA-12519 TNS : No app
-
I have some socket code that works fine in Windows and Mac. However, the socket wont connect or throw an error in the Linux flash player (debug or normal). Below is a code fragment. I can't find any reference to any special circumstances for Linux. I
-
I need your help with next script. I get a good digitaltimer script but I need to play a movieclip when 3 passes using the digitaltimer script. The digitaltimer script is: //initial variables var timing:Boolean = false; var paused:Boolean = false; va
-
With Apple discontinuing support jre 7 on its mountain lion, i am trying to find a way to launch my mac apps with oracle jre7. There are two situations occuring to me. 1. Oracle jre7 could be before hand installed and my app should be able to detect