Matrix x System Form x UDO
Hey all,
I´m asking for some help to deal with the following:
I want to show a new Matrix in a System Form. The data is from a UDO (line data - detail).
How should i do that ? Can i use UDO methods ? Anyone can help me ?
Hi Christiano,
If you are modifying a System Form then you cannot use the UDO methods to save everything automatically. How you will add your matrix to the system form? Are you adding a new folder?
If you want to use the UDO methods then you need to create a separate form linked to your UDO. In this case you can add a button to the system form opening your form.
Hope it helps
Trinidad.
Similar Messages
-
Problem with AddRow() in custom matrix on System Form
Hello all,
I'm trying to add 1 row to a custom matrix on a system form (Sales Quotation).
However I always get a RPC_E_SERVERFAULT exception when calling pMatrix.AddRow() and SBO crashes...
My code is simple:
[B1Listener(BoEventTypes.et_CLICK, false)]
public virtual void OnAfterClick(ItemEvent pVal)
Form pForm = B1Connections.theAppl.Forms.Item(pVal.FormUID);
// Add matrix line
Matrix pMatrix = (Matrix) pForm.Items.Item("MATRIX").Specific;
pMatrix.AddRow();
// Set matrix line data
The matrix shows ok in the system form, inside a new folder.
What is the problem with my code?
Is there any way to add rows to a custom matrix in a system form?
This code runs ok if executed in a custom form...
Thanks!
Manuel Diashi.
R u facing any problem ...
actually add row and del row both are same.
in normal customization form and system form matrx...
Any problem are u facing... -
How to add new columns in predefined matrix in system form
Hi all,
I am new to SAP B1. I am going to add New column to Good Receipt PO matrix. I faced the one error " Matrix Line Exists " While adding new column to good receipt PO matrix".
=========================================================
Private Sub SBO_Application_ItemEvent(ByVal FormUID As String, ByRef pVal As SAPbouiCOM.ItemEvent, ByRef BubbleEvent As Boolean) Handles SBO_Application.ItemEvent
oMat = oForm.Items.Item("38").Specific
oCols = oMat.Columns
oCol = oCols.Item("U_MyCol")
If pVal.EventType = SAPbouiCOM.BoEventTypes.et_FORM_LOAD And pVal.BeforeAction = True And pVal.FormType = "143" Then
Try
oForm = SBO_Application.Forms.Item(pVal.FormUID)
oMat = oForm.Items.Item("38").Specific
oCols = oMat.Columns
'oCol = oCols.Item("U_MyCol1")
oCol = oCols.Add("U_MyCol1", SAPbouiCOM.BoFormItemTypes.it_EDIT)
oCol.TitleObject.Caption = "Qty Accepted"
oCol.Width = 40
oCol.Editable = True
oCol = oCols.Item("U_MyCol1")
Catch ex As Exception
SBO_Application.MessageBox(ex.Message)
End Try
End If
oDBDataSource = oForm.DataSources.DBDataSources.Add("PDN1")
''oEdit.DataBind.SetBound(True, "PDN1", "U_QtyAccepted")
============================================================
And i also added for Datasource to Databind. what there is no result ??i wanted Clear information regarding this to add new columns in matrix in middle of Matrix items. I wanted Clear coding& information for this to add new Columns in Matrix ?help me regarding this asap??
Regards
ANANDAnand,
If you use the "search" feature of this forum and type "add column", you will find many posts that may help you such as this one ...
How to add a column on sales order matrix?
HTH,
Eddy -
How to achieve matrix cell value of systems forms matrix ?
Hi,
When user types data in perticular cell of matrix in system Form , i want to achieve that data.
How can i achieve that data ?
Do any one have some sample code plz. fwd it.
Regards,
GaneshHi Makarand,
This should do the trick.
<b>Code (C#):</b>
public override void Handle_ItemEvent(string FormUID, ref ItemEvent pVal, out bool BubblesEvent)
/* Switch by eventtype */
switch(pVal.EventType)
case BoEventTypes.et_VALIDATE:
/* Get a matrix object */
Matrix oMatrix = (Matrix)SBO_Application.Forms.Item(FormUID).Items.Item("MY_MATRIX_ID").Specific;
/* Get a EditText object for the matrix cell */
EditText oEdit = (EditText)oMatrix.Columns.Item("COLUMN_ID").Cells.Item("ROW_NUMBER").Specific;
/* Get the value from the object */
string sValue = oEdit.Value;
/* Do other things you like ;) */
break;
Hope it helps,
Rowdy -
Is it possible to get System form Matrix Data in DI API?
HI,
i would like to use DI API to get the System Form Matrix ( like Sale Order ) . Is it possible?
i know that using UI API is most easier way. However, UI API cause extermemly slow perfomance.
no matter i use Form.Freeze or not. Please Advise
Thanks
Gordon
Edited by: Gordon Ho on May 7, 2009 7:03 AMHi,
U can access the Sales Order rows using the DI only if its added to the system. U can use the DOCUMENT object and Document.Lines and access the row data. Please check the SDK help file for more information.
From SDK Help
Document_Lines is a child object of Documents object and represents the line entries of a document in the Marketing Documents and Receipts module and the Inventory and Production module.
Vasu Natari. -
I want add new column in matrix in "Inventory Transfer" Form (System Form)
hai,
i want to add new column in Matrix in "Inventory Transfer" Form (System Form)
Is it possible or not?
bye
gopinathhai,
i want coding how to add columns in the matrix ( system form)
plz....
bye
gopi
Edited by: Rui Pereira on Dec 23, 2008 4:45 PM -
How do load system form matrix -Inventory-Goods Issue through SDK UI &DI
While I am accessing system form matrix -Inventory Goods Issue/ Goods Receipt, the matrix object is not accessible.
Error is coming stating "Item 13 is invalid, where 13 is item uid for matrix.
So,How do load system form matrix -Inventory-Goods Issue(FORM 720/-720) through SDK UI &DIAPI.
Form Type: -720
How to get reference of System form matrix object -Inventory-GoodsIssue.
Some thing similar to CopyFrom functionality for -Inventory-Goods Issue.
Currently my client requirement is as follows.
I created a UDF ((U_ILC) Incoming Log Challan) for marketing documents. And, this field is added in the header level of Goods Reciept, Goods Issue documents.
1. Through Inventory->Goods Receipt (ILCNo.10), items are received. Assume, M00001, M00002 are the items received with qty, price, whse, account values.
2. Through Inventory->Goods Issue, item should be issued. In this Goods Issue Form, after entering U_ILC value as 10, pressing Tab, the GoodsIssue matrix should be loaded with the values of GoodsReceipt(IGN1 for U_ILC:10) document i.e. M00001,M00002 along with the same values as in GoodsReceipt of ILC:10.
The code is as follows:
If (( ( pVal.FormType = "-720" or pVal.FormType = 720) And pVal.EventType <> SAPbouiCOM.BoEventTypes.et_FORM_UNLOAD) And (pVal.Before_Action = False)) Then
'// get the event sending form
oForm = SBO_Application.Forms.GetFormByTypeAndCount(pVal.FormType, pVal.FormTypeCount)
If pVal.ItemUID = "U_ILCNo" And pVal.EventType = SAPbouiCOM.BoEventTypes.et_LOST_FOCUS And pVal.Before_Action = False Then
SBO_Application.MessageBox("ILC No. Lost Focus")
oMatrix = oForm.Items.Item("13").Specific
oColumn = oForm.Columns.Item("1")
oEditItmCode = oColumn.Cells.Item(1).Specific
oEditItmCode.Value = "07215090x606"
oItem = oForm.Items.Item("U_ILCNo")
oEdit = oItem.Specific
SBO_Application.MessageBox(oEdit.String)
End If
End If
3. The code
oMatrix = oForm.Items.Item("13").Specific
is raising error. I have used Event Logger and breakpoints to see where the code is halting.
Help me, how to access the matrix of Goods Receipt/ Goods Issue and load based on the existing data.
Thanks in advanceHI
If your code is in the SBO_Application_ItemEvent then try using this line
oForm = SBO_Application.Forms.Item(strFormUID)
instead of
oForm = SBO_Application.Forms.GetFormByTypeAndCount(pVal.FormType, pVal.FormTypeCount) -
Simple problem with popup message before adding document on system form
Hi all,
We have an AddOn that validates price lines on system Sales Order form matrix, so that if prices fall below a certain value, a popup is show to ask to continue or not, when user presses ADD button.
The problem is that if he chooses yes (to continue), the Sales Order is not added since the button ADD keeps being selected ....
Here is my code:
[B1Listener(BoEventTypes.et_CLICK, true)]
public virtual bool OnBeforeClick(ItemEvent pVal)
int iResult = B1Connections.theAppl.MessageBox("Price lines fall bellow minimum! Continue?", 1, "NO", "YES", "");
if (iResult == 1) // NO
// Show error
B1Connections.theAppl.StatusBar.SetText("OK", SAPbouiCOM.BoMessageTime.bmt_Short, SAPbouiCOM.BoStatusBarMessageType.smt_Error);
return false;
// YES: Continue to add Sales Order
return true;
The problem is somehow related with the popup message being shown: if user says YES to continue, the system form does not continue with the standard process of adding the Sales Order (when I move the cursor above the ADD button is shows it already pressed...).
Do I have to do anything more to force the process to continue, when the user says YES?
Regards,
Manuel DiasThtas known problem. The solution for this is declare global variable as boolean, when user selects Yes, then set this variable to true and emulate click to add button again where before the message box check if its varaible sets to true - in this case dont show message box, only set variable to false.
The concept of code will be
dim continue as boolean = false
in item event
if continue = false then
x = messagebox...
if x = 1 then
continue = true
items.item("1").click
end if
else
continue = false
end if -
HI
We r assuming " freezing = Absent"
When we select " freezing" in the combo box in the system form, "Absent" should be displayed in the matrix for the particular row in the user form.
Freezing should be displayed as Absent
Working should be displayed as Present
what is the coding for this process . can anyone help me...
Regards
Bhuvana
Edited by: bhuvana eshwari on Jul 30, 2008 6:45 AMHi Bhuvana,
In the combo Select Event, get the user form and then get the matrix then set the value. The code sample is as follows.
Case SAPbouiCOM.BoEventTypes.et_COMBO_SELECT
If oCmbBox.Selected.Value = Freezing Then
oForm = getForm("UserFormID")
objMatrix = oForm.Items.Item("UID").Specific
objedit = objMatrix.Columns.Item("V_14").Cells.Item(pVal.Row).Specific
ObjEdit.String = Absent
ElseIF oCmbBox.Selected.Value = Working
'Use same logic
EndIF
Reward with points if helpful.
Regards,
Vasu Natari. -
Is it possible to create an additional matrix on a system form? If so, how? I would greatly appreciate a code sample for doing this. Thank you.
hello Scott,
You need to catch the et_Form_Load event of your form, and then you can add the matrix the same way you add matrix on user form.
Public Sub Handle_SBO_ItemEvent(ByVal FormUID As String, ByRef pVal As SAPbouiCOM.ItemEvent, ByRef BubbleEvent As Boolean) Handles oApplication.ItemEvent
If pVal.BeforeAction = False Then
If pVal.FormTypeEx="FormType of the system form" then
If pVal.EventType = SAPbouiCOM.BoEventTypes.et_FORM_LOAD Then
Dim oFom as SAPbouiCOM.Form
oForm = oApplication.Forms.Item(FormUID)
Dim oItem As SAPbouiCOM.Item
Dim oMatrix As SAPbouiCOM.Matrix
Dim oColumns As SAPbouiCOM.Columns
Dim oColumn As SAPbouiCOM.Column
oItem = oForm.Items.Add("UMatrix", it_Matrix)
oItem.Top=100
oItem.Left=100
oMatrix = oItem.Specific
oColumns = oMatrix.Columns
oColumn = oColumns.Add("#", it_EDIT)
oColumn.TitleObject.Caption = "#"
oColumn = oColumns.Add("A", it_EDIT)
oColumn.TitleObject.Caption = "A"
oColumn = oColumns.Add("B", it_EDIT)
oColumn.TitleObject.Caption = "B"
End if
End if
end if
End Sub -
System form oMatrix.LoadFromDataSource()
Hi all ,
Am try to load some 100 rows to the purchase credit memo matrix so i use this code below
frmPCM.Freeze(True)
oMatrix.FlushToDataSource() ========> error message (Item - The item is not a user-defined item [66000-8])
=====
======
oDBDSDetail.SetValue("U_Excamount", pVal.Row - 1,1)
======
oMatrix.LoadFromDataSource()
frmPCM.Freeze(false)
it is possible in system form ?Hi Jaba,
You cannot use the following methods on the system form for Matrix object. Because of this you are getting the error. These methods are :
SetLineData, SelectRow, LoadFromDataSource, FlushToDataSource
Hope it helps.
Thanks & Regards
Ankit Chauhan -
Item ID for Minimize, Maximize button at system form title bar
Hi,
Can anyone help me out finding Item ID for Minimize, Maximize and close buttons at system form title bar (Left side Title of form and right side three buttons). I need ID for these items, if anyone knows please reply. will appreciate help on same.
Thanks,
JayI'm tryin to get over with Item master screen strech machenism. I've Added matrix at pane 6 and position is not fixed when ever form is rezised or base product font size is changed. I've alredy tried providing values to top left width height through oexisting item vaues, I'm not using any integer value. Let me know if i can freez it's position ....... Sample code below
oExistingItem = oForm.Items.Item("174")
oItem = oForm.Items.Add("mtx_MFGALS", SAPbouiCOM.BoFormItemTypes.it_MATRIX)
oItem.Top = oExistingItem.Top + oExistingItem.Height + oExistingItem.Height
oItem.Width = oExistingItem.Width + oExistingItem.Width
oItem.Height = oExistingItem.Width
oItem.Left = oExistingItem.Left
oItem.FromPane = "6"
oItem.ToPane = "6"
oMatrix = oItem.Specific
oMatrix.Columns.Add("Col0", SAPbouiCOM.BoFormItemTypes.it_EDIT)
oMatrix.Columns.Item("Col0").TitleObject.Caption = "Line #"
oMatrix.Columns.Add("Col1", SAPbouiCOM.BoFormItemTypes.it_EDIT)
oMatrix.Columns.Item("Col1").TitleObject.Caption = "Name"
oMatrix.AutoResizeColumns()
Regards,
Jay -
I created new table in database and want to bind with system form
Hi All,
1) i created new table in database and want to bind with system form .
2) How i bind this field to system form sale order where i added new folder tab in that i added some fields that fields i want to bind with database. when i click on the next ,previous ,first and last button
bind value should change.
Awaiting soon reply
Rajkumar G.hi,
try this
Public Sub BindDataToForm()
Dim oItem As SAPbouiCOM.Item
Dim oEdit As SAPbouiCOM.EditText
Dim oComboBox As SAPbouiCOM.ComboBox
'// getting the matrix column by the UID
'oItem = oForm.Items.Item("docname")
'oComboBox = oItem.Specific
'oComboBox.DataBind.SetBound(True, "OSRI", "BaseType")
'oItem = oForm.Items.Item("docno")
'oEdit = oItem.Specific
'oEdit.DataBind.SetBound(True, "OSRI", "BaseEntry")
oColumn = oColumns.Item("Code")
'oColumn.DataBind.SetBound(True, "", "DSCardCode")
oColumn.DataBind.SetBound(True, "OSRI", "ItemCode")
oColumn = oColumns.Item("Serial")
oColumn.DataBind.SetBound(True, "OSRI", "IntrSerial")
Try
oColumn = oColumns.Item("Inspection")
oColumn.DataBind.SetBound(True, "OSRI", "U_Inspection")
Catch ex As Exception
MessageBox.Show(ex.Message)
End Try
oColumn = oColumns.Item("Quality")
oColumn.DataBind.SetBound(True, "OSRI", "U_Quality")
oColumn = oColumns.Item("Status")
oColumn.DataBind.SetBound(True, "OSRI", "U_Status")
oColumn = oColumns.Item("Finish")
oColumn.DataBind.SetBound(True, "OSRI", "U_Finish")
oColumn = oColumns.Item("Thickness")
oColumn.DataBind.SetBound(True, "OSRI", "U_Thickness")
oColumn = oColumns.Item("uom")
oColumn.DataBind.SetBound(True, "OSRI", "U_NetUOM")
oColumn = oColumns.Item("length")
oColumn.DataBind.SetBound(True, "OSRI", "U_Length")
oColumn = oColumns.Item("height")
oColumn.DataBind.SetBound(True, "OSRI", "U_Height")
oColumn = oColumns.Item("sqf")
oColumn.DataBind.SetBound(True, "OSRI", "U_sqf")
oColumn = oColumns.Item("sqm")
oColumn.DataBind.SetBound(True, "OSRI", "U_sqm")
End Sub -
How to use existing form with UDO
Hi
I want to use Sales order form with a new UDO. Is it possible that one form work with More than one object.
I want that when we click on User defined menu then same existing SAP form of Sales order will open with A new UDO( contains master and child tables). Or we have to create a replica of that sales order form.
Thx.The system forms are not released as UDOs... UDOs can only be used with Userforms
-
Hi,
I am urgently in need of help on opening a system from a user form. I want to use a link arrow on a matrix and go to a particular record on the system form.
For example I'd like to go to the record with deposit number 16 on the deposit screen.
Thanks.
TayoHello Tayo,
you just need to create an arrow, define it taget (Form type) and link it to a cell or a texte box that contains the id (16 in your case)
Dim oItem As SAPbouiCOM.Item
Dim oLink As SAPbouiCOM.LinkedButton
Set oItem = oForm.Add("A", it_LINKED_BUTTON)
oItem.Linkto = "YourTexteBox"
Set oLink = oItem .ExtendedObject
oLink.LinkedObject = lf_lf_Deposit
In a matrix, you need to change oitem to Column object.
I think there is a sample in the UI sample called 06.MatrixAndDataSources that have a sample of linked button in a Matrix
Message was edited by: Sébastien Danober
Maybe you are looking for
-
How to modify a VAC in a standard FPM Application
Hello All, I have a requirement in the project where I have to modify the standard SAP delivered FPM application. But this does not involve any creation of new webdynpro iview , but to modify a VAC in the application. It is related to essbensap.com,
-
Error -12 when building installer LV2012
When I try to build an installer from the project menu I immediatly get en error -12. (see attached) This has happened on several different projects. I can make an .EXE, Zip file and distribution build but not installer. I read the "Why Does My Distr
-
Tomcat+Cocoon : error of pipeline
Hello, I've installed Tomcat and Cocoon ; Tomcat works fine but when I want to reach Cocoon (http://localhost:8888/cocoon) I've got the following error : org.apache.cocoon.ResourceNotFoundException: No pipeline matched request: index.htmlIn the Cocoo
-
What is a SB protocol in OSB??
hi, what is a SB protocol in OSB and for wich service we use. please someone help me and if some one have an example please give me. thank you aymen
-
How to start extern videos and apps?
Hi, I try to figgure out to start some Captivate -videos and some applicaions in a Flash 8 CD/DVD-Menu. Is there a helpfile, sample or template available? It would be a big help why I'm new in this business. Thanks a lot for any help, Wolf