C
CG Rosén
Good Morning Group,
Have some problem with a presentation of values in a textbox.
The code below works fine and presents the values in a Textbox in UserForm1.
The Cells(1,1) is formated as 'number' with 2 decimals. When the value in
the cell is of the type xxxx,00 (the decimal values are zero) the Textbox
does not show this, but just xxxx. Is there a way to have the Textbox to
show these decimals even if they are zero?
Brgds
CG Rosén
n = Application.WorksheetFunction.Sum(Sheets(1).Range(Sheets(1).Cells(r, 1),
Sheets(1).Cells(r, 20)))
Worksheets(2).Cells(1, 1) = n
UserForm1.Label1.Caption = Round(Worksheets(2).Cells(1, 1), 2)
Have some problem with a presentation of values in a textbox.
The code below works fine and presents the values in a Textbox in UserForm1.
The Cells(1,1) is formated as 'number' with 2 decimals. When the value in
the cell is of the type xxxx,00 (the decimal values are zero) the Textbox
does not show this, but just xxxx. Is there a way to have the Textbox to
show these decimals even if they are zero?
Brgds
CG Rosén
n = Application.WorksheetFunction.Sum(Sheets(1).Range(Sheets(1).Cells(r, 1),
Sheets(1).Cells(r, 20)))
Worksheets(2).Cells(1, 1) = n
UserForm1.Label1.Caption = Round(Worksheets(2).Cells(1, 1), 2)