Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Perpetual string math calculator.
#5
It represent it mathematically correctly in Visual Basic 5.0. Then that probably also applies to QuickBasic 4.5.

There is a bug in the QB64 math rounding routines.  Dodgy

Code: (Select All)
Option Explicit

Private Sub cmdCommand_Click()

  Dim Zahl1, Zahl2, Ergebnis As Double
 
  Ergebnis = Val(txtZahl1.Text + txtZahl2.Text)
  txtErgebnis.Text = Format$(Ergebnis, "###.##")

End Sub

Private Sub cmdEnde_Click()
  End
End Sub

Private Sub cmdLoeschen_Click()
  txtZahl1.Text = ""
  txtZahl2.Text = ""
  txtErgebnis.Text = ""
End Sub

[Image: Korrektes-Runden2022-08-11-221242.jpg]
Reply


Messages In This Thread
Perpetual string math calculator. - by Pete - 08-10-2022, 05:11 PM
RE: Perpetual string math calculator. - by Pete - 08-11-2022, 03:24 AM
RE: Perpetual string math calculator. - by Pete - 08-11-2022, 12:39 PM
RE: Perpetual string math calculator. - by Pete - 08-11-2022, 08:29 PM
RE: Perpetual string math calculator. - by Kernelpanic - 08-11-2022, 08:25 PM
RE: Perpetual string math calculator. - by Pete - 08-11-2022, 10:08 PM
RE: Perpetual string math calculator. - by bplus - 08-11-2022, 10:07 PM
RE: Perpetual string math calculator. - by Jack - 08-11-2022, 10:35 PM
RE: Perpetual string math calculator. - by Pete - 08-11-2022, 11:35 PM
RE: Perpetual string math calculator. - by Jack - 08-11-2022, 11:42 PM
RE: Perpetual string math calculator. - by Pete - 08-11-2022, 11:51 PM
RE: Perpetual string math calculator. - by Pete - 08-12-2022, 01:56 AM



Users browsing this thread: 15 Guest(s)