locked
mini super calculator - need help ! RRS feed

  • Question

  • I started to build a mini calculator, 11 x 18-cells, and that adds the cells vertically and horizontally ( only additions allowed to date ).

    new version: program no: TWW791

    You enter numbers, (positive and negative) then you click compute, and additions are made.

    You can also write new numbers in cells and click COMPUTE button again , and additions results are updated.

    QUESTION:   how to display in red negative addition results and in blue positive ones?

    help needed!

    program: CDF928


    • Edited by YLedEditor Sunday, May 15, 2016 5:14 PM new version
    Saturday, May 14, 2016 9:14 PM
    Answerer

Answers

  • Yled  see CDF928-0

     

    GraphicsWindow.brushColor statement  should be written  before  Controls.AddTextBox()

    Sunday, May 15, 2016 1:23 AM
    Answerer

All replies

  • ...by changing the Brush-/PenColor to "Red" for a negative result and to "Blue" for a positive result.

     ...with LDShapes.BrushColour(shapeName, colour) for TB background

        or LDShapes.PenColour(shapeName, colour)  for text in TB.

    Saturday, May 14, 2016 9:29 PM
    Answerer
  • Thanks very much ! i'll try this :)
    Sunday, May 15, 2016 12:54 AM
    Answerer
  • Yled  see CDF928-0

     

    GraphicsWindow.brushColor statement  should be written  before  Controls.AddTextBox()

    Sunday, May 15, 2016 1:23 AM
    Answerer
  • @NaochanON

    thanks ! very well good solution , work fine, easy to understand!

    here the result so far: CDF928-1


    • Edited by YLedEditor Sunday, May 15, 2016 2:15 AM
    Sunday, May 15, 2016 2:02 AM
    Answerer