Combo inside matrix, help me
Dear all,
In my application i have combox in matrix, Values of combo i added (1, 2,3,4...). now when user click button in form it will assign for combobox is 1 or 2 ..... I try this code but error"
oComboBox = oMatrix.Columns.Item(colName.ToString).Cells.Item(i + 1).Specific()
oComboBox.Select(1, SAPbouiCOM.BoSearchKey.psk_ByValue)
Please help me. THanks
What is the error message?
Im using it as
For q = 1 To Matrix.RowCount
com = Matrix.Columns.Item("c1").Cells.Item(q).Specific
com.Select(0, SAPbouiCOM.BoSearchKey.psk_Index)
Next q
and its working.
Similar Messages
-
Hi,
I have a Matrix.
In Each row i want like to populate matrix with values based on the row.
My problem is once a combo gets populated in one row, the same value
gets populated for other rows also(inspite of changing values)
This is my code
Do Until rsWHID.EoF = True
i = i + 1
Dim sLength As String
sLength = rsWHID.Fields.Item("Length").Value
WHOH_Form.DataSources.UserDataSources.Item("usLot").ValueEx = ""
Dim sDate As String = Convert.ToString(rsWHID.Fields.Item("DueDate").Value)
WHOH_Form.DataSources.UserDataSources.Item("usDate").ValueEx = Convert.ToString(sDate).Replace(".", "")
WHOH_Matrix.AddRow()
sQuerySOWO = "select u_ORDER,U_SOWO from [@CDIplanorders] WHERE u_iTEMcODE='" & sItemNo & "' AND u_lENGTH='" & sLength & "'"
rsSOWO.DoQuery(sQuerySOWO)
WHOH_Form.DataSources.UserDataSources.Item("usCmboSOWO").ValueEx = ""
WHOH_Combo = WHOH_Matrix.Columns.Item("cmbSOWO").Cells.Item(i).Specific
For j = WHOH_Combo.ValidValues.Count - 1 To 0 Step -1
WHOH_Combo.ValidValues.Remove(j, SAPbouiCOM.BoSearchKey.psk_Index)
Next j
If Not rsSOWO.EoF() Then
Do Until rsSOWO.EoF = True
Dim strOrderNO, strWOorSO As String
strOrderNO = rsSOWO.Fields.Item("u_ORDER").Value
strWOorSO = rsSOWO.Fields.Item("u_SOWO").Value
WHOH_Combo.ValidValues.Add(strOrderNO, strWOorSO)
rsSOWO.MoveNext()
Loop
End If
rsWHID.MoveNext()
Loop
Pls help.The design of the matrix implies that all row-comboboxes have the same data, you cannot change that.
Maybe use the double click event to popup a form and show the different possible values depending on the row -
Hi,
How can I populate a combo box in a matrix with different values?
The combobox will have a dynamic data coming from a table for each description.
Supposed, if I my matrix would look like the following.
Description Option(combobox)
ABC Yes/No
DEF Excellent/Good/Poor
GHI High/Medium/Low
How would I do it?
Thanks,Hi jaun,
you write the code in Key_Down Event Of Description field
'Assuming clCombo as Combobox column,DESCUID as Description field ColUID and it is Edit Text
If Description field is also combo box then you add this code in Combo_Select in before action false
if pVal.ColUid="DESCUID" and Pval.Row>0 then
dim objCombo as SAPbobsUICOM.ComboBox
dim i as integer
objCombo =objMatrix.Columns.Item("clCombo").Cells.Item(Pval.Row).Specific
for int=0 to objCombo.ValidValues.Count-1
objCombo.ValidValues.Remove(0)
Next
if objMatrix.Columns.Item("DESCUID").Cells.Item(Pval.Row).Specific.Value="ABC" then
objCombo.ValidValues.ADD("Y","YES")
objCombo.ValidValues.ADD("N","NO")
end if
if objMatrix.Columns.Item("DESCUID").Cells.Item(Pval.Row).Specific.Value="ABC" then
objCombo.ValidValues.ADD("E","EXCLLENT")
objCombo.ValidValues.ADD("G","GOOD")
objCombo.ValidValues.ADD("P","POOR")
end if
if objMatrix.Columns.Item("DESCUID").Cells.Item(Pval.Row).Specific.Value="ABC" then
objCombo.ValidValues.ADD("H","HIGH")
objCombo.ValidValues.ADD("M","MEDIUM")
objCombo.ValidValues.ADD("L","LOW")
end if
End if
Hope it helps you
Regards
Vishnu -
Hi,
How do I check whether a combo is selected? The combo is bind to the matrix using screen painter.
I have tried this but it is not working:
oMatrix.Columns("ColName").Cells.Item(i).Specific.Selected.Value = ""
I am using VB and 2004B. Help appreciated.Hi,
If ((pVal.EventType = SAPbouiCOM.BoEventTypes.et_GOT_FOCUS And pVal.ItemUID = "Matrix1" And pVal.ColUID = "ColumnID" And pVal.Before_Action = False)) Then
oCombo = oMatrix.Columns.Item(pVal.ColUID).Cells.Item(pVal.Row).Specific
If oCombo.Selected Is Nothing Then
oCombo.Select(0, SAPbouiCOM.BoSearchKey.psk_Index)
Else
SBO_Application.MessageBox("Combo selected")
End If
End If
This event gives me a selection even before losing the focus of combobox item.
Hope it may be of use to u.
Cheers
Manu -
hi
im using combo in my matrix
how to load data from database table to column(ocombo) of the matrix
plz help me
Edited by: hareeshKR on Jul 18, 2011 12:37 PM
Edited by: hareeshKR on Jul 18, 2011 1:15 PMHi,
ObjMatrix = ObjForm.Items.Item("6").Specific
ObjCombo = ObjMatrix.Columns.Item("4").Cells.Item(row).Specific
strSQL="Select Code,ItemName from OITM"
obRS= objAddOn.objCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
objRS.doQuery(strSQL)
for i=1 to objRS.recordcount
ObjCombo.ValidValues.Add(ObjRS.Fields.Item("Code").Value, ObjRS.Fields.Item("ItemName").Value)
ObjRS.MoveNext()
Next -
As stated above, when I start Mac it shows a white screen with an image of a folder with a ? inside it.
I have shut it down by holding the power button then pulled the power cord waited 10mins and restarted for the same result.
Any help would be great.Cheers for the info Allan.
I unfortunately do not have a back up. It is in the hands of the repairer now, fingers crossed they can save my stuff.
FYI, i'll be backing up in future. -
Headphone jack broken off inside Macbook--HELP!
My dad recently gave me his MacBook Pro, only problem is the audio is completely broken. This occurred when the computer was on the bed with headphones were plugged into the headphone port, and the dog jumped on the headphone jack, breaking it off inside of the computer.... The piece is totally irretrievable; it's broken off far inside of the headphone port. My father contacted the Apple store and I contacted Mac Mall, and they both said the same thing--it will have to be taken apart, and could cost up to $900 to fix!!!
This is a huge expense that I would like to avoid if possible..... my question is, is there any way to get around this problem? Is there any way I can get audio without having the computer taken apart to get the broken headphone piece out? Are there perhaps external speakers that work through the USB port? Or is there a way to change the settings so the computer doesn't acknowledge that there is something plugged in the headphone port? I really don't know! I'm totally desperate. Anything helps. Thanks!Yes, easy way around it.
look up a JEWELRY REPAIR place, usually they charge $30 or $40
they drill into the back of the jack, then insert a mini jewelers screw and yank it out. Ive done it myself for a customer long ago.
Many jewelry repair people do such things. -
Prob in retaining spaces in Combo Box, PLEASE HELP ASAP!!
Hi
In the application that I am working on, I have developed a screen wherein I populate the names of some schemes from the database, in a combo box (<Select><option></option></Select>).
A particular scheme in the database has a multiple-word name with double spaces between the two words, or rather between the last of the two words and the brackets.
e.g. Help CRY (Child Relief & You).
Now, when this name is fetched fro the database, the double spaces between the CRY and ( are retained but when I display them in the combo box, i.e. between the <option> tags, somehow the double spaces disappear.
Further on, in my servlet, I retrieve the same scheme name from the combo box and try to fetch some other entries from the database. At that point, since one of the spaces has disappeared, there is no database match found for the scheme name selected and I'm unable to proceed. This problem arises in the case of any number of spaces between the words while populating the combo box. It however works fine when I remove the double spaces and retain a single space between the words.
Please let me know ASAP if combo boxes eat up such spaces and convert any number of spaces into a single space as a property or is something wrong with the JSP I have here. If this problem can never be resolved as a rule, then please tell me so that I can force the data providers to make sure they filter out such double spaces before sending the data to our databases.
I'll be very grateful if your can help me out asap as we have to put up the site at the earliest possible date.
Thanks a lot,
Soumyawhy not you try to set the option value, like this:
<option value="Help CRY (Child Relief & You)">words you wan display</option>
Think if the display is not right it will not affect you from extracting the value.
Regards,
Jas -
Matrix - Help with setting 1st column for line numbers
Hi,
I have created a matrix on a custom form and would like to add line numbers to the # column line that of the quotation screen.
The matrix itself is populated correct from the Query and LoadFromDataSource, and all the fields and columns are filled in correctly, the only column I am having trouble with is the 1st one for line numbers. My code for adding the line numbers is
SBO_Application.MessageBox("Matrix Count: " & tMatrix.RowCount)
For i = 1 To tMatrix.RowCount
oEditText = tColumns.Item("#").Cells.Item(i).Specific
oEditText.Value = i
Next
For the example I am using I get the message box appear:
Matrix Count: 26
So I know I should have the line number go from 1 to 26, however I only get 1 to 9 displayed, all the remaining lines are blank.
Any ideas on why it stops at 9 or what I should do to correctly set the line numbers in the Number column like that of the system Quotation/Sales orders forms.
Your help is much appreciated
MatthewHi,
I tried changing it to the following as you suggested:
SBO_Application.MessageBox("Matrix Count: " & tMatrix.VisualRowCount)
For i = 1 To tMatrix.VisualRowCount
oEditText = tColumns.Item("#").Cells.Item(i).Specific
oEditText.Value = i
Next
The message box still displays 26, however my lines still only go up to number 9.
Thanks for the quick response. -
Hi All,
I have created a matrix with priceunitColumn.this field is linked to a no Object type table.My problem is iam not getting the define new option in the combo.Also i cant get all the values from the table in the combo.How should i achieve this.
Thanx in advance.
Regards
MohanaHi..
Try this code it will work..
Dim oPopUp As SAPbouiCOM.Form REM Define New Form (Global)
Private Sub LoadFromXml(ByVal fileName As String)
Dim XmlDoc As Xml.XmlDocument
Dim Xmlstr As String
XmlDoc = New Xml.XmlDocument
Dim SPath As String
Try
SPath = IO.Directory.GetParent(Application.StartupPath).ToString
XmlDoc.Load("C:\Program Files\SAP\SAP Business One\AddOns\Ur Srf Folder" & "\" & fileName)
SBO_Application.LoadBatchActions(XmlDoc.InnerXml)
oPopUp = SBO_Application.Forms.Item("define sfr form ID")
Catch ex As Exception
SBO_Application.MessageBox(ex.Message)
End Try
oPopUp.Visible = True
End Sub
Item Event
If pVal.FormUID = "UID" And pVal.ItemUID = "ComboID" And pVal.BeforeAction = False And pVal.EventType = SAPbouiCOM.BoEventTypes.et_COMBO_SELECT Then
Try
ocombo = FormS.Items.Item("ID").Specific
If ocombo.Selected.Value = "-9" Then
LoadFromXml("Define NewSRF .srf")
End If
Catch ex As Exception
SBO_Application.MessageBox(ex.Message)
End Try
End If
Regards..
Billa 2007 -
How to add combo in system matrix ? I am adding a column in the matrix of A/R invoice.I am using the following code-
Dim matMatrix As SAPbouiCOM.Matrix
Dim objColumn As SAPbouiCOM.Column
Dim ddlAP As SAPbouiCOM.ComboBox
objForm = SBO_Application.Forms.ActiveForm
If objForm.DataSources.UserDataSources.Count = 228 Then
objForm.DataSources.UserDataSources.Add("ddlAP", SAPbouiCOM.BoDataType.dt_LONG_TEXT, 50)
End If
matMatrix = objForm.Items.Item("38").Specific
matMatrix.Clear()
If matMatrix.Columns.Count = 265 Then
objColumn = matMatrix.Columns.Add("AP", SAPbouiCOM.BoFormItemTypes.it_COMBO_BOX)
Else
objColumn = matMatrix.Columns.Item("AP")
End If
objColumn.DataBind.SetBound(True, "", "ddlAP")
'objColumn.TitleObject.Caption = "AP Invoice"
objColumn.Width = 100
objColumn.Visible = True
matMatrix.Columns.Item("AP").DisplayDesc = True
matMatrix.Columns.Item("AP").TitleObject.Caption = "A/P Invoice"
ddlAP = matMatrix.Columns.Item("AP").Cells.Item(0).Specific
objForm.Refresh()
But the combo is note getting displayed.Hi Dilip,
You cannot change (add or modify) a system matrix via SDK. If you need to add a ComboBox in a system matrix you need to create a UserField with ValidValue or connected to a User Table.
Regards,
Vítor Vieira -
Here is the code, flash plays fine in chrome even after publishing and making live on web. But anyone with IE gets all my page but no flash menus or anything. Have not tried FF. Please help Im going nuts on this one. Im using Visual Studio 2010 RC. This is my first attempt and page is great in chrome.
<%@ master language="C#" autoeventwireup="true" inherits="MasterPage, App_Web_zu1uh2td" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>dreamtemplates</title>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1251" />
<link href="style.css" rel="stylesheet" type="text/css" />
<script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript">
AC_FL_RunContent('codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0', 'width', '780', 'height', '327', 'src', '3439', 'quality', 'high', 'pluginspage', 'http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash', 'movie', '3439'); //end AC code
</script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="780" height="327">
<param name="movie" value="3439.swf" />
<param name="quality" value="high" />
<embed src="3439.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="780" height="327"></embed>
</object>
</noscript>
<asp:ContentPlaceHolder id="head" runat="server">
</asp:ContentPlaceHolder>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<form id="form1" runat="server">
<div>
<asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
</asp:ContentPlaceHolder>
</div>
</form>
<table width="780" border="0" cellspacing="0" cellpadding="10">
<tr>
<td align="center" bgcolor="#181818">Copyright © Company name. 2008 | <a href="#" class="orange-text-regular">privacy policy</a></td>
</tr>
</table>
</body>
</html>Hiya, Mike,
It's pretty tough to work through pasted-in code. If you can, please upload a page to a server, so we can see your pages in context. We'll be able to download it and look at it.
That said, you can do this: Find the beginning of an editable region in Code View. It will look like this:
<!-- InstanceBeginEditable name="nameofregionhere" -->
Click anywhere in that tag, between the opening bracket and the closing bracket.
Then, on the vertical toolbar on the left side of the Code window, click on the "Collapse Full Tag" button. It is the one with two arrows pointing at each other. This will collapse that entire editable region. Then click the button with the two arrows pointing away from each other. That will re-open the editable region, but will highlight it.
If you have nested regions, you will find the other inside one of the editable regions. If you copy the <!-- InstanceBeginEditable and do a search on it in that document, you will find the nested region.
Beth -
Very Urgent - Matrix Help Required
Hi Guys,
I am making a matrix report in which there are 3 cells.I am taking this report format into excel with fields as comma seperated so in the layout i had put ',' after every field.But in matrix if there is no record for that row and column it doesnt print ' ,' which is in the cell.But i want that to print so the layout will be proper.Please if anyone can help me out in this issue.
My query is very huge so i cant do much with that.Hemant,
it doesn't print ' ,' because the field doesn't exist and is not formated then. The same issue you have, if you wan't to print 0, if the value of the cell is null (doesn't exist). There's a trick to get the wished output. Create a boilerplate you like (' ,') and bring this behind the repeating frame of the group for the cell. Then use "white" fill color for this repeating frame or the cell-field. So ' ,' is there every time, but will be covered when a real value exists. If there's no value, no object will hide this boilerplate.
Hope that helps
Rainer
P.S.: I've used this with Reports 2.5 years ago and hopefully it works with 10g. -
Hola a todos.... el problema que tengo y espero me puedan ayudar es que tengo un matrix de sap, pero nesesito que una de las columnas de ese matrix en ves de mostrar texto me muestre un combo con informnacion de los turnos de una empresa ....alguien me puede ayudar .. este es el codigo que estoy ocupando:
For Li_Fila = 0 To Lo_Personal.TotalFilas - 1
Lo_Personal.Fila = Li_Fila
Lo_UserDataSource = Mo_Forma.DataSources.UserDataSources.Item(MatrixCambiaTurnosNumero)
Lo_UserDataSource.Value = Lo_Personal.Empleado
Lo_UserDataSource = Mo_Forma.DataSources.UserDataSources.Item(MatrixCambiaTurnosOriginal)
Lo_UserDataSource.Value = Lo_Personal.TurnoDescripcion
''En esta columna es en la que deseo mostrar el combo.....
__Lo_UserDataSource = Mo_Forma.DataSources.UserDataSources.Item(MatrixCambiaTurnosCambio)__
__Lo_UserDataSource.Value =Lo_cboTunos.Selected.Description__
Lo_grdMatrixCambiaTurnos.AddRow()
Next
Asi como lo tengo ahora me muestra la forma de combo con un valor pero al darle click no me despliega el resto de los valores....
alguien sabe como puedo solucionar esto
De antemano les agradesco ....Jorge Luis
Sobre el punto que mencionas te puedo decir lo siguiente:
' Creando los UserDataSources para la columna tipo combo
oMyForm.DataSources.UserDataSources.Add("udsColumna", SAPbouiCOM.BoDataType.dt_SHORT_TEXT)
oMatrix = oMyForm.Items.Item(MyMatrix).Specific
oColumns = oMatrix.Columns
' Asignando el UserDataSources a la columna tipo combo
oColumns.Item("c_Columna").DataBind.SetBound(True, "", "udsColumna")
oMatrix = oMyForm.Items.Item(MyMatrix).Specific
oColumns = oMatrix.Columns
' Agregando valores al combo de la columna tipo combo
oColumns.Item("c_Columna").ValidValues.Add("M", "Mañana")
oColumns.Item("c_Columna").ValidValues.Add("T", "Tarde")
oColumns.Item("c_Columna").ValidValues.Add("N", "Noche")
oColumns.Item("c_Columna").DisplayDesc = True
oRecordSet.DoQuery("SELECT CODE, NAME FROM [@TABLE]")
Dim index As Integer = 1
' Cargando valores a las filas de la matrix
oMatrix = oMyForm.Items.Item(MyMatrix).Specific
While Not oRecordSet.EoF
oMatrix.AddRow(1)
oMatrix.GetLineData(index)
oUserDataSource = oMyForm.DataSources.UserDataSources.Item("udsColumna")
oUserDataSource.Value = oRecordSet.Fields.Item("CODE").Value.ToString.Trim
oMatrix.SetLineData(index)
index += 1
oRecordSet.MoveNext()
End While
Si revisas bien este codigo primero llenas la columna que es tipo combo con sus valores posibles, puedes usar un oRecordSet para llenarla si es que los datos los tienes en una tabla y pueden varias.
Al usar UserDataSource en una matrix debes usar las funciones GetLineData(index) y SetLineData(index).
Bueno espero que esto aclare tus dudas, si todo sale bien seria bueno que lo comentes.
Saludos
George -
CD Jammed Inside MacBook HELP!!!
I put in a CD into my macbook to add it into iTunes, it made a loud buzzing noise, wouldn't recognize the CD, so I ejected it.. it made a loud click noise and now it's stuck inside the CD Drive!! Does anyone know how to get it out? PLEASE HELP!
If you cant eject the CD using the above method, but you are able to boot into the OS. open up terminal and type in the following command, this will force a software eject of the disk.
DRUTIL eject
if you have more than one optical drive attached to the system, type
DRUTIL List
this will list all the optical drives attached to the system, then just use the eject command as above but put the drive number at the end of the command, (eg: drutil eject 1)
more info can be found here
http://developer.apple.com/documentation/Darwin/Reference/ManPages/man1/drutil.1 .html
Maybe you are looking for
-
Double image when printing labels
I am copying in a graphic for Avery round labels. Everything looks fine on the screen, but when printed, some (not all) of the labels have the image, plus a smaller version of the image on top of it. Kind of like an inset. I have reloaded the printer
-
Web service proxy generation validation failed - two declarations collision
Hi, I'm creating a JAX-WS web service proxy against a web service with very complex payload. When I point the wizard to the WSDL, during the analysis, it throws an error, Error creating model from wsdl "<mywsdl>": (Related to above error) This is the
-
LC_APPL_ERROR in /SAPAPO/OM_ORDER_GET_DATA
Hi All, I'm using /SAPAPO/OM_ORDER_GET_DATA to fetch the orders from liveCache. But I'm facing the error LC_APPL_ERROR randomly for certain records. Why does this error LC_APPL_ERROR rise? What can be done to avoid this error? Pls help...this is an u
-
Details on FILLW time's operation
When Manager selects alternative payment for employee, the ALP code on shift premium time types is lost some where in time schema. Basically, the time schema compares the actual start time with different time slots to assign shift premium. We are usi
-
Hi all , Is there any upgrade path from UCCX 9.0 to PCCE ? Because one of our customers (Telecom service providers) are looking for a contact centre with minimum options and later upgarde to a fully fledged system with minimum cost , Please advice wh