Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2018
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.68 KB | None | 0 0
  1. Sub Макрос1()
  2.  
  3. Dim a As Double
  4. Dim b As Double
  5. Dim c As Double
  6.  
  7. [C2].value = ""
  8. [C3].value = ""
  9. [C4].value = ""
  10. [C5].value = ""
  11.  
  12. a = [B2].value
  13. b = [B3].value
  14. c = [B4].value
  15.  
  16. If (a < 0 Or b < 0 Or c < 0) Then
  17. If (a < 0) Then
  18. [C2].value = "Отрицательное"
  19. End If
  20. If (b < 0) Then
  21. [C3].value = "Отрицательное"
  22. End If
  23. If (c < 0) Then
  24. [C4].value = "Отрицательное"
  25. End If
  26. Else
  27. [C5].value = "Все значения положительные"
  28.  
  29. End If
  30.  
  31. End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement