質問編集履歴

3

コード

2017/06/13 07:46

投稿

10morokoshi
10morokoshi

スコア14

test CHANGED
File without changes
test CHANGED
@@ -36,6 +36,14 @@
36
36
 
37
37
  'このとき、何行目か?
38
38
 
39
+
40
+
41
+ Else
42
+
43
+ i += 1
44
+
45
+ '他もろもろいろいろ処理が必要かと思いますが本題ではないので省略します。
46
+
39
47
  End If
40
48
 
41
49
  Next

2

コード修正

2017/06/13 07:46

投稿

10morokoshi
10morokoshi

スコア14

test CHANGED
File without changes
test CHANGED
@@ -22,8 +22,6 @@
22
22
 
23
23
  ```ここに言語を入力
24
24
 
25
- Dim count As Integer = DataGridView1.RowCount
26
-
27
25
  Dim A As Integer = 0
28
26
 
29
27
 

1

言語追加

2017/06/13 07:44

投稿

10morokoshi
10morokoshi

スコア14

test CHANGED
File without changes
test CHANGED
@@ -13,3 +13,33 @@
13
13
  ![イメージ説明](52e6a5311786a2546a3c700ac8a9eaab.png)
14
14
 
15
15
  ex:12を指定したら、0を取得したい
16
+
17
+
18
+
19
+
20
+
21
+ いただいた回答を参考にして自分なりに書いてみましたが何行目かを取得する方法がわかりません…。
22
+
23
+ ```ここに言語を入力
24
+
25
+ Dim count As Integer = DataGridView1.RowCount
26
+
27
+ Dim A As Integer = 0
28
+
29
+
30
+
31
+ For i = 0 To 5
32
+
33
+ A = DataGridView1.Rows(i).Cells("列A").Value
34
+
35
+
36
+
37
+ If A = 12 Then
38
+
39
+ 'このとき、何行目か?
40
+
41
+ End If
42
+
43
+ Next
44
+
45
+ ```