Advertisement
Guest User

Untitled

a guest
Aug 19th, 2017
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. Workbooks.Open (fPath & sName)
  2.  
  3. Sheets(1).Select
  4.  
  5. ActiveSheet.Shapes.Range(Array("TextBox1")).Select
  6.  
  7. With Selection.ShapeRange(1).TextFrame2.TextRange.Characters(1, 262).Font.Fill
  8. .Visible = msoTrue
  9. .ForeColor.RGB = RGB(255, 0, 0)
  10. .Transparency = 0
  11. .Solid
  12. End With
  13.  
  14. CharCount = Len(textbox1.Text)
  15.  
  16. Sheets(1).Select
  17. ActiveSheet.TextBox1.ForeColor = RGB(255, 0, 0)
  18.  
  19. Dim wb As Workbook
  20. Dim ws As Worksheet
  21. Dim s As Shape
  22.  
  23. Set wb = Workbooks.Open(fPath & sName)
  24. Set ws = wb.Sheets(1)
  25. Set s = ws.Shapes("TextBox 1")
  26.  
  27. s.TextFrame2.TextRange.Font.Fill.ForeColor.RGB = RGB(255, 0, 0)
  28.  
  29. Sub Button2()
  30. Dim sh As Shape
  31. Set sh = Sheets("Sheet1").Shapes("Textbox1")
  32. sh.TextFrame.Characters.Font.Color = vbRed
  33. End Sub
  34.  
  35. Private Sub M_in_out_LostFocus()
  36. Dim sh As Sheet7
  37. Set sh = Sheet7
  38.  
  39. vx = CInt(M_in_out.Value)
  40. If vx > 0 Then
  41. sh.M_in_out.ForeColor = vbBlack
  42. Else
  43. sh.M_in_out.ForeColor = vbRed
  44. End If
  45.  
  46. sh.Cells(23, 6).Value = sh.Cells(23, 6).Value + vx
  47. End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement