|
- Function LL(JSS, Optional X) 'キオサリシニヒ羯ォハスオトヨオサオオトシニヒ羯ォハス
- Dim S%, E%
- Dim JS As String
- If JSS = "" Then
- LL = ""
- Else
- If IsMissing(X) Then 'キオサリシニヒ羯ォハスオトヨオ
- If Left(JSS.Value, 1) = "=" Then
- JSS = Mid(JSS, 2)
- End If
- Do Until InStr(1, JSS, "。セ") = 0
- S = InStr(1, JSS, "。セ")
- E = InStr(1, JSS, "。ソ")
- JSS = Left(JSS, S - 1) & Mid(JSS, E + 1)
- Loop
- a = Len(JSS)
- Select Case a
- Case Is < 248
- LL = Evaluate("=" & JSS)
- Case Is < 494
- LL = Evaluate(Mid(JSS, 1, 247)) + Evaluate(Mid(JSS, 248, Len(JSS) - 247))
- Case Is < 986
- LL = Evaluate(Mid(JSS, 1, 247)) + Evaluate(Mid(JSS, 248, 246)) + Evaluate(Mid(JSS, 495, Len(JSS) - 494))
- End Select
- ElseIf X = 2 Then 'キオサリヨオオトシニヒ羯ォハスサノシニヒ羞トア昻・スサオアセノ・
- If JSS.HasFormula = True Then
- LL = Mid(JSS.Formula, 2)
- Else
- If IsNumeric(Evaluate(JSS.Value)) = True Then
- LL = JSS.Value
- Else
- JS = JSS.Value
- Do Until InStr(1, JSS, "。セ") = 0
- S = InStr(1, JSS, "。セ")
- E = InStr(1, JSS, "。ソ")
- JSS = Left(JSS, S - 1) & Mid(JSS, E + 1)
- Loop
- If IsNumeric(JSS) = True Or IsNumeric(Evaluate(JSS)) = True Then
- LL = JS
- End If
- End If
- End If
- End If
- End If
- End Function
复制代码 |
|