Adding new items in ME21N using USEREXIT/BADI with BOM explosion
I have following business scenario. There is purchase requisition consisting just one material. In ME21N we are creating new purchase order. This purchase order needs to consist that item (we drag&drop this item from purchase requisition).
The problem is, that this item is in fact BOM, so we would like to explode it and select just some entries from them basing on some Z* configuration and we can't use standard BOM explosion from ME21N.
The idea to solve that issue is following:
1. Explode there BOM for material;
2. Filter out not needed items from that explosion using Z-config table;
3. Copy filtered items using USER-EXIT / BADI , ENHANCEMENT-SPOT into purchase order items.
The best, if this USER-EXIT / BADI, ENHANCEMENT-SPOT will be used only when drag&drop purchase requisition item into new purchase order.
The point is that I'm not able to find out such USER-EXIT, BADI or ENHANCEMENT-SPOT.
P.S. There is for instance exit "MM06E007 Change document for requisitions upon conversion into PO", but interface of that exit completely doesn't fit my needs.
Any ideas?
Hello Tomasz Suchanek ,
There is no BADI/ Enhancement Spots / User Exits that you can use for this requirement.
You are trying to change the SAP standard Functionality.
You need to contact SAP for consulting .
Thanks,
Greetson
Similar Messages
-
How to create new subsite while adding new item to the list by using javascript?
hi,
I hav a task ie, when I add item to the list then subsite will create with that list item title and description . So By using javascript, I have to create subsite while adding new item to the list.
Help me to solve this.
Thank you,Is your item getting added through Javascript client object model ? If yes, you can write in the success delegate of your list creation method the logic to create the subsite.
function CreateListItem()
var clientContext = new SP.ClientContext.get_current();
var oList = clientContext.get_web().get_lists().getByTitle('List Name');
var itemCreateInfo = new SP.ListItemCreationInformation();
this.oListItem = oList.addItem(itemCreateInfo);
oListItem.set_item('Title', 'My New Item!');
oListItem.set_item('Body', 'Hello World!');
oListItem.update();
clientContext.load(oListItem);
clientContext.executeQueryAsync(Function.createDelegate(this, this.CreateListItemOnSuccess), Function.createDelegate(this, this.onQueryFailed));
function CreateListItemOnSuccess() {
var subsiteTitle = oListItem.get_item('Title');
//Logic to create a subsite
function onQueryFailed(sender, args) {
I have added a sample flow for the above scenario. Have a look at the following lnk for how you can craete a subsite using ecmascript.
http://ravisoftltd.wordpress.com/2013/03/06/sharepoint-2010-create-site-with-ecma-script-with/
Geetanjali Arora | My blogs | -
My old MacBook pro died, got a new Mac can I use my cs4 with my new computer?
MMy old MacBook pro died, got a new Mac, can I use my cs4 with my new computer? Do I need to buy a new license?
Using Time Machine, or any other such program, to transfer Adobe software from one machine to another works probably less than five percent of the time. Uninstall from your new machine. Run the cleaner tool (do a search for Cleaner Tool on this site if you don't know what it is). Then reinstall properly from original media or downloads.
--OB -
Hi,
I want to add 5 new fileds in the header level & item level of Me21N screen. The suggestion i have got is use <b>badi</b> <b>customer own screens in enjoy purchase order</b>. Please let me know the method to use for this badi or another way to add custom fileds to it.
Please send the sample code if anybody is having.
Please tell me the procedure to add the fields.
many thnx & rgds.Hi,
Another way of doing the same is to use screen-exits for the transaction. You can use the standard enhancement MM06E005 in SMOD for the Purchasing related custom fields. You can add the fields in the screens 0101, 0111 of program SAPLXM06 to get the fields in the tab 'Customer Data' at header level and item level for ME* transactions.
EXIT_SAPMM06E_006
EXIT_SAPMM06E_007
EXIT_SAPMM06E_008
are the function modules where u need to do the coding.
and the fields u have added need to be included in the includes
CI_EKKODB
CI_EKPODB
of EKKO and EKPO for header level and item level respectively.
Regards,
Vishnu Priya
Message was edited by:
Vishnu priya
Message was edited by:
Vishnu priya -
How to create new tab in Me21N using enhancement MM06E005
Hi All,
Can u guys please tell me know to create a new tab at item level in purhcase order ME21N using enhancement MM06E005.
Thanks in advance.
Thanks,
Jaffer Ali.SPlease search the forum:
addition of new tab (reasons) on me21n (item level)
Re: Adding a new Tab - ME22n - Item Detail Level -
Add new Item in VL02n using idocs - delivery returns
Hello Experts,
I am using idoc type DELVRY03. I need to add a new line item while changing the outbound delivery (vl02n) "USING the IDOCs only" and not by adding it manually in the outbound delivery change (vl02n).This item does not prexist in sales order. Instead, after triggering the idoc type DELVRY03, i need to see this new item in vl02n.
I am unable to get proper qualifier to "ADD" new item in any segments of DELVRY03.
Any help would be appreciated by rewarding points.
thanks
Harikumar GantiHi.
Could u solve this problem?
Im trying the same with idoc DELVRY03 message type WHSCON and I can't add a new item in the delivery.
Thanks a lot!!!
Regards -
Hi all,
We have a requirement from business, basically:
1) we receive sales order with item A,B and C (any qty).
2) We deliver them in one delivery note and good issue.
3) We receive a POD wich confirm A, and c item, but item B was really item X (change of code, or new item at delivery)
asuming inventory has to be solved, but we need to invoice (bill) right qties and items, adding to delivery or pod the new item.
Any clue about how best to solve it ?Hi Goverdhan,
try with this BADI: CJ_DOCUMENT
Reddy -
Hi,
when adding a new item in SAP GUI, we get an option for the connection type------
Custom application server
Group/Server selection
On selection the Group/Server selection
we need to add the System ID, Message server, SAP Router and Group/Server.
Here on adding the first two and then when i go on adding the Group/Server, I get the Error message as
Hostname <message server name> not found.
Is there anything i need to do in the HOST file or the Service file present at the Drivers folder of my local PC.Hi Subhram
Firstly you need to check if connections to the specified servers are allowed through your network. Check if access is permitted on those group servers from your network.Check your VPN settings.
Secondly check the Saplogon.ini file in the C:\WINDOWS folder. Check if the entries are correctly maintained in there as well.
I hope this helps
Regards
Chen -
The cart was not being updated. Firefox recommended all history for this website be cleared. All History was cleared. It resolved the problem of adding items to the cart. But now there is a new problem. The item in the cart is being replaced by new items ordered. So the cart has only ONE (The latest item ordered) in the cart. How can I resolve this issue?
Thanks... I got it....
-
Use of CS_BOM_EXPL_MAT_V2 fro BOM explosion on plant basis
hello ,
I dont have any documentation for this FM and need to use it for BOM explosion on plant basis plz let me knw how to use it?Try something like this :
* Tables "call CS_BOM_EXPL_MAT_V2 "
DATA: BEGIN OF t_stb OCCURS 0.
INCLUDE STRUCTURE stpox.
DATA: END OF t_stb.
DATA: BEGIN OF matcat OCCURS 50.
INCLUDE STRUCTURE cscmat.
DATA: END OF matcat.
CALL FUNCTION 'CS_BOM_EXPL_MAT_V2'
EXPORTING
auskz = ' '
capid = 'PP01'
datuv = sy-datum
emeng = '1.000'
stlan = '1'
stlal = mast-stlal
mtnrv = matnr
mehrs = 'X'
mmory = '1'
stpst = '0'
werks = werks
IMPORTING
topmat = selpool
dstst = dstst_flg
TABLES
stb = stb
matcat = matcat
EXCEPTIONS
material_not_found = 4
no_plant_data = 8
no_bom_found = 12
no_suitable_bom_found = 16.
Hope this helps,
Erwan -
Adding new field in ME21N items level NO ADDITIONAL TAB or SUBSCREEN
Hello Gurus!!
I have a requirement where I am just trying to add a new field ZZ*** at Item level in ME21N (and no new tabs please)
I got the modification key and now wat i see is that in screen 1211 SAP has some field mappings with metadata.
Refer to Include LMEMFSF0T.
Can you please help me how sud i proceed or wat can be an alternate way out to solve.
regards,
Prasenjit Singh BistHi,
Another way of doing the same is to use screen-exits for the transaction. You can use the standard enhancement MM06E005 in SMOD for the Purchasing related custom fields. You can add the fields in the screens 0101, 0111 of program SAPLXM06 to get the fields in the tab 'Customer Data' at header level and item level for ME* transactions.
EXIT_SAPMM06E_006
EXIT_SAPMM06E_007
EXIT_SAPMM06E_008
are the function modules where u need to do the coding.
and the fields u have added need to be included in the includes
CI_EKKODB
CI_EKPODB
of EKKO and EKPO for header level and item level respectively.
Regards,
Vishnu Priya
Message was edited by:
Vishnu priya
Message was edited by:
Vishnu priya -
I have two Lists i.e. Publisher and Products in my SharePoint Online site. They are having the following structures:
1. Publisher:
Publisher (Single line of txt)
A1
A2
A3
A4
A5
A6
2. Products:
Publisher (lookup to the above column)
ProductName (Single line of txt)
A1 Apple
A2 Samsung
A3 Nokia
And I have an excel file named Products.xlsx in my local machine which has the following data:
Publisher ProductName
A1 Apple
A2 Samsung
A3 Nokia
A4 Motorola
A5 LG
A6 HTC
Now I have written the below client-side (CSOM) code to fetch the data from the Excel and update the corresponding fields in the Products table:
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Web;
using System.IO;
using System.Data;
using System.Data.OleDb;
using System.Data.SqlClient;
using System.Linq;
using System.Text;
using System.Xml.Linq;
using Microsoft.SharePoint;
using Microsoft.SharePoint.Client;
using File =
Microsoft.SharePoint.Client.File;
using System.Security;
namespace ExcelToSP
public class
ExcelToSP
//Main function to get the command line values and invoke the getSPList function to pull SP List data
public
static void Main(string[] args)
//Instantiate Class object
ExcelToSP p
= new ExcelToSP();
try
p.LoadExcelData();
//Exit with Sucess code
Environment.Exit(0);
catch
(Exception ex)
//Invoke writeErrorLog function to log the exception details
//p.WriteErrorLog(ex);
public
void LoadExcelData()
try
string fileName
= @"E:\Products.xlsx";
string fileExtension
= Path.GetExtension(fileName).ToUpper();
string connectionString
= "";
if
(fileExtension == ".XLS")
connectionString
= "Provider=Microsoft.Jet.OLEDB.4.0;Data Source='"
+ fileName + "'; Extended Properties='Excel 8.0;HDR=YES;'";
else
if (fileExtension ==
".XLSX")
connectionString
= "Provider=Microsoft.ACE.OLEDB.12.0;Data Source='"
+ fileName + "';Extended Properties='Excel 12.0 Xml;HDR=YES;'";
if
(!(string.IsNullOrEmpty(connectionString)))
string[] sheetNames =
GetExcelSheetNames(connectionString);
if ((sheetNames !=
null) &&
(sheetNames.Length
> 0))
DataTable dt = null;
OleDbConnection con =
new OleDbConnection(connectionString);
OleDbDataAdapter da =
new OleDbDataAdapter("SELECT * FROM ["
+ sheetNames[0]
+ "]", con);
dt
= new DataTable();
da.Fill(dt);
InsertIntoList(dt,"Products");
catch
(Exception ex)
throw ex;
private
string[] GetExcelSheetNames(string strConnection)
var connectionString
= strConnection;
String[] excelSheets;
using
(var connection =
new OleDbConnection(connectionString))
connection.Open();
var dt = connection.GetOleDbSchemaTable(OleDbSchemaGuid.Tables,
null);
if (dt ==
null)
return null;
excelSheets
= new String[dt.Rows.Count];
int i = 0;
// Add the sheet name to the string array.
foreach (DataRow row
in dt.Rows)
excelSheets[i]
= row["TABLE_NAME"].ToString();
i++;
return excelSheets;
private
void InsertIntoList(DataTable listTable,
string ListName)
try
string username = "[email protected]";
string pwd = "contoso@1234";//this.Dts.Variables["password"].Value.ToString();
ClientContext clientContext =
new ClientContext("https://contoso.sharepoint.com/teams/myPOC/");
SecureString password =
new SecureString();
char[] decryptpwd = pwd.ToCharArray();
foreach (char c
in decryptpwd)
password.AppendChar(c);
clientContext.Credentials
= new SharePointOnlineCredentials(username, password);
clientContext.ExecuteQuery();
//Setting SiteURL Client context
Web web = clientContext.Web;//
clientContext.Load(web);
clientContext.ExecuteQuery();
List lstProductFamily = web.Lists.GetByTitle("Products");
for (int iRow
= 0; iRow < listTable.Rows.Count; iRow++)
ListItemCreationInformation itemCreateInfo =
new ListItemCreationInformation();
ListItem newItem = lstProductFamily.AddItem(itemCreateInfo);
//FieldLookupValue flv = newItem["Publisher"] as FieldLookupValue ;
//string lkup = flv.LookupValue;
//int valueid = 0;
//valueid = flv.LookupId;
newItem["Publisher"]
= Convert.ToString(listTable.Rows[iRow][0]);
newItem["ProductName"]
= Convert.ToString(listTable.Rows[iRow][1]);
newItem.Update();
clientContext.ExecuteQuery();
catch
(Exception ex)
throw ex;
But I'm getting the following error on running the above code "Invalid data has been used to update the list item. The field you are trying to update may be read only."
Can anybody please help me out?Hi,
According to your description, my understanding is that you want to update data to look up field.
I have a test about updating look up field using Client Object Model in my environment. lookup field will accept an array to set the field value.
Here is the code snippet:
Microsoft.SharePoint.Client.ClientContext ctx = new ClientContext("http://sp2013sps/sites/test/");
if (ctx != null)
List list = ctx.Web.Lists.GetByTitle("List3");
ListItem itemToUpdate = list.GetItemById(1);
ctx.Load(itemToUpdate);
ctx.ExecuteQuery();
FieldLookupValue newLookUpField = new FieldLookupValue();
newLookUpField.LookupId = 3;
FieldLookupValue newLookUpField1 = new FieldLookupValue();
newLookUpField1.LookupId = 4;
FieldLookupValue[] newarr = { newLookUpField, newLookUpField1 };
itemToUpdate["lookup"] = newarr;
itemToUpdate.Update();
ctx.Load(itemToUpdate);
ctx.ExecuteQuery();
Best regards
Patrick Liang
TechNet Community Support -
Adding new items in Contract created by referring to a quotation
Dear experts,
I have been asked to enhance the contract creation process when it is created by referring to a quotation. The enhancement should make 1 item with quantity=3 in quotation appear as 3 items with quantity=1 in the contract.
By making an enhancement in USEREXIT_CHECK_VBAP of SAPMV45A, I have been able to split the single item read from the quotation into 3 line items - but unfortunately I still unable to do the same with their pricing conditions and billing plan. My thinking is that there must exist a routine to recalculate pricing conditions of each items in the original program. But what is that and how to use it is something that I need to know.
Please give me some light on this... Thanks.HI
GOOD
TRY TO USE THE USER EXITS AMONG THESE
SDTRM001 Reschedule schedule lines without a new ATP check
V45A0002 Predefine sold-to party in sales document
V45A0003 Collector for customer function modulpool MV45A
V45A0004 Copy packing proposal
V45E0001 Update the purchase order from the sales order
V45E0002 Data transfer in procurement elements (PRreq., assembly)
V45L0001 SD component supplier processing (customer enhancements)
V45P0001 SD customer function for cross-company code sales
V45S0001 Update sales document from configuration
V45S0003 MRP-relevance for incomplete configuration
V45S0004 Effectivity type in sales order
V45W0001 SD Service Management: Forward Contract Data to Item
V46H0001 SD Customer functions for resource-related billing
V60F0001 SD Billing plan (customer enhancement) diff. to billing p
SDAPO001 Activating Sourcing Subitem Quantity Propagation
V45A0001 Determine alternative materials for product selection
THANKS
MRUTYUN^ -
Adding new rows to table - using TableRowSorter & RowFilter
Hi all,
I have a table where the user can add new rows by selecting a JButton. I have added a text box which allows the user to search for a String value and this filters the table contents and this is all working fine...But when I go to add a new row I get the following exception:
java.lang.IndexOutOfBoundsException: Invalid range which seems to originate from DefaultRowSorter.rowsInsertedCould someone please give me any ideas to why this is happening, maybe the number of rows that are in the table orginally is set to x and when I add a new row the TableRowSorter is expecting that number not x + 1 which is added due to the button being pressed?
Seems like I need to update the TableRowSorter to inform it that a new row has been added or something similar to that,
Thanks,If you need further help then you need to create a [Short, Self Contained, Compilable and Executable, Example Program (SSCCE)|http://homepage1.nifty.com/algafield/sscce.html], that demonstrates the incorrect behaviour.
Don't forget to use the Code Formatting Tags so the posted code retains its original formatting. That is done by selecting the code and then clicking on the "Code" button above the question input area. -
Hi Gurus,
m added 5 custom fields in PO header customer data.
for tht, include of EKKO added 5 fields.
m using enhancement MM06E005 for screen layout and updation,'
1) EXIT_SAPMM06E_007 (PAI) - Export data
2) EXIT_SAPMM06E_006 (PBO)
3) EXIT_SAPMM06E_008 Import data.
In screen layout added all the fields from dictionary.
Question:
Now i want to update data in EXIT_SAPMM06E_008 --> E_CI_EKKO-ZLEVR ,
BUT i cant able to assign values to this EXIT_SAPMM06E_008 enhancement.
throwing error EKKO is unknown.
please suggest me the flow. how to update data.
where to assign and initialise.
Thanks and Regards
Vinayak SapkalHi,
problem solved... m using global structure EKKO_CI and on screen all field name given like
EKKO_CI-zlevr,EKKO_CI-zmdsp....
there is no req. of Import n Export if using EKKO_CI structure...
Just pass this structure value in Import exit EXIT_SAPMM06E_008.
E_CI_EKKO is changing.so value will be save in EKKO table.
IF EKKO_CI-ZLEVR IS NOT INITIAL.
E_CI_EKKO-ZLEVR = EKKO_CI-ZLEVR.
ENDIF.
Thanks all you guys for your suggestions...
Thanks and Regards
Vinayak sapkal
Maybe you are looking for
-
Copy SMS from iphone 3g to iphone 4? is it possible
Hi, any way to copy my SMS (Only SMS) from my 3g to my new iphone 4? i already have my contacts and Notes online, i still have many SMS that i need but at the same time, i don't want to restore from the 3g backup. my 3g was jailbroken/unlocked with a
-
I have a question and are in need of some advice. I would like to apply for American express blue cash card. I am just wondering i it woud be worth the hard pull n case of denial. My current fico scores are for TU-733 EXP-740 EQ-738. My utilizatio
-
Error in Cisco 2500 series Wireless Controller
I have this error in Cisco 2500 series Wireless Controller The AP type Cisco AIR-CAP35021-A-K9 I cann't connect the client to AP when i try to connect i get this error on Cisco 2500 series Wireless Controller But the AP get ip . Please can any on
-
Songs and albums that I have already purchased appear available to buy again. Even If I try to buy them (again) I get not notification that I have already purchased it before. I have reset all relative warnings in itunes account. Shouldn't they be gr
-
Hello. I have an iPhone 4S and downloaded the new iOS 6. My phone is not turning off, not connecting after do not disturb feature is back on, problems with Passbook, Maps, and not downloading Kayak app. what should I do????