0
私は次のようにコードを実行しています。私の入力が「アイテムA」で、その範囲に少なくとも5つの「アイテムA」がある場合、その範囲内の結果の数をどのように数えますか?range.searchの結果の数を数える方法
私はitemfound.Count
を試しましたが、出力数は数字の数にかかわらず一貫して1です。
string a = "C" + nInLastRow.ToString();
Microsoft.Office.Interop.Excel.Range finditemrange =
Main_Menu.mainitemworksheet.get_Range("C1", a);
Microsoft.Office.Interop.Excel.Range itemfound = finditemrange.Find(itemComboBox.Text,
misValue, Excel.XlFindLookIn.xlValues, Excel.XlLookAt.xlPart,
Excel.XlSearchOrder.xlByColumns, Excel.XlSearchDirection.xlNext,