Can you give us an example of what you are trying to do? Can you list a simple case with the contents of two comboboxes and what you want to see as a result?

i have one combobox that have an price item and the other one have an QTY i need to multiply each item the show the result of sum in textbox , can anyone help plx
thx before :D

i want to calculate the total cost of Eq from two combobox
my code is
Dim sum As Integer

For j = 0 To Me.ComboBox8.MaxLength
sum += ComboBox8.SelectedValue * ComboBox9.SelectedValue

Next

totalallcosttxt.Text += sum
but its calculate for the selected item not for all item or value
i try to do this from datagridview but i cant arrive to the clos value , can u help plz

The ComboBox is a combination of a TextBox and a ListBox. The ComboBox displays an editing field (TextBox) combined with a ListBox allowing us to select from the list or to enter new text.
That means that you only can calculate the selected items in both your comboboxes.

Thr following code assumes integer values in columns 0 and 1 of a datagridview. It calculates column0 + column1 and puts the result in column2. Use CDbl for floating point values. To calculate the total sum just keep a running total of the values in column2

For Each row As DataGridViewRow In DataGridView1.Rows
row.Cells(2).Value = CInt(row.Cells(0).Value) + CInt(row.Cells(1).Value)
Next

Need some help with this Array. I am trying to get the sum of the even numbers and the sum of the odd numbers using a for each loop. I know the answers to what I am trying to achive are sum of even = 84 and the sum of ...

When I execute this progammatically, I get a table with row heights much larger than when I do this manually.

Note : Sel is the Word.Selection object and the Clipboard contains an Excel Table.

public void AddClipboard()
{
Sel.PasteExcelTable(false,false, false);
var t = Sel.Tables[Sel.Tables.Count];
t.AutoFitBehavior(Word.WdAutoFitBehavior.wdAutoFitContent);
}

I have a 2d matrix with dimension (3, n) called A, I want to calculate the normalization and cross product of two arrays (b,z) (see the code please) for each column (for the first column, then the second one and so on).
the function that I created to find the ...