swChef Active Member Licensed User Longtime User Sep 8, 2013 #1 If I do the following Code: Copy Dim fCtoFa As Float = 0.0 Dim fCtoFb As Float = 0.0 sb.Append(fCtoFa).Append(" ").Append(fCtoFb) LabelA.Text = sb If fCtoFa and fCtoFb are both 0, the Label displays "0 0". If fCtoFa is 1.8 and fCtoFb is 32.0, the Label displays "1.8 523162842". If I reverse the appends, doing fCtoFb first, then fCtoFa, then the Label displays "32 1.8". I had also tried Dim fCtoFb As Int = 0, that made no difference. ?
If I do the following Code: Copy Dim fCtoFa As Float = 0.0 Dim fCtoFb As Float = 0.0 sb.Append(fCtoFa).Append(" ").Append(fCtoFb) LabelA.Text = sb If fCtoFa and fCtoFb are both 0, the Label displays "0 0". If fCtoFa is 1.8 and fCtoFb is 32.0, the Label displays "1.8 523162842". If I reverse the appends, doing fCtoFb first, then fCtoFa, then the Label displays "32 1.8". I had also tried Dim fCtoFb As Int = 0, that made no difference. ?
Erel B4X founder Staff member Licensed User Longtime User Sep 8, 2013 #2 I'm unable to reproduce it. Tried it with this code: Code: Copy Dim fCtoFa As Float = 1.8 Dim fCtoFb As Float = 32.0 Dim sb As StringBuilder sb.Initialize sb.Append(fCtoFb).Append(" ").Append(fCtoFa) Log(sb) Can you upload your project (File - Export as zip)? Upvote 0
I'm unable to reproduce it. Tried it with this code: Code: Copy Dim fCtoFa As Float = 1.8 Dim fCtoFb As Float = 32.0 Dim sb As StringBuilder sb.Initialize sb.Append(fCtoFb).Append(" ").Append(fCtoFa) Log(sb) Can you upload your project (File - Export as zip)?