- Oct 2, 2008
- Office Version
Private Sub UserForm_Initialize() Filmprofit.Value = 0 'setting the default value to 0 when form loads End Sub
Private Sub AddFilmbutton_Click() ActiveCell.Offset(0, 1).Value = Filmprofit ActiveCell.Offset(0, 1).NumberFormat = Range("c3").NumberFormat ' to change the format to Currency End Sub
I am entering numbers through textbox named Filmprofit.
As shown in below picture, the Profit amounts are reflecting the Green error mark which says "Convert to Number", Ignore error, etc.
I can see that the number format is changed to Currency but the cells are still showing error.
I believe the numbers entered in text-box is getting entered in cells as text; due to this currency format is not working.
Any thoughts and solution on this please?