Open "C:sakuin.csv" For Input As #1
for x=1 to 47
Input #1,name[x]
next
while Eof(1)=0
for x=1 to 47
Input #1,data
if zm=data then
fname="C:"+name[x]
Open fname For Input As #2
while Eof(2)=0
for q=1 to 15
Input #2,data
da[q]=data
next
if da[3]=z then
jusho=da[4]+da[5]+da[6] msgbox 0,jusho,""
ed=1
Exit While
end if
wend
close #2
Exit For
endif
next
if ed=1 then Exit while
wend
close #1
dim data As String
dim name[47] As String
dim da[15] As String
dim q As Long
dim x As Long
dim z As String
dim zm As String
dim ed As Long
dim fname As String
Open "C:sakuin.csv" For Input As #1
for x=1 to 47
Input #1,name[x]
next
while Eof(1)=0
for x=1 to 47
Input #1,data
if zm=data then
fname="C:"+name[x]
Open fname For Input As #2
while Eof(2)=0
for q=1 to 15
Input #2,data
da[q]=data
next
if da[3]=z then
jusho=da[4]+da[5]+da[6]
msgbox 0,jusho,""
ed=1
Exit While
end if
wend
close #2
Exit For
endif
next
if ed=1 then Exit while
wend
close #1