View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Norman Jones[_2_] Norman Jones[_2_] is offline
external usenet poster
 
Posts: 421
Default View Numbers in Textbox in Proper Format in UserForm

Hi Shahzad4u,

Try using the TextBox's Text property,
rather than its value property.

Therfore, try, for example, somthing like:

'=========
Private Sub UserForm_Initialize()
Dim WB As Workbook
Dim SH As Worksheet

Set WB = thisworkboook
Set SH = WB.Sheets("Sheet1") '<<==== CHANGE

Me.TextBox1.Value = ActiveSheet.Range("A1").Text

End Sub
'<<=========




---
Regards.
Norman


wrote in message
...

Hi,

I have one Userform having Textbox2 to show the Value of the Total
amount from the worksheet.

I mean in Sheet1, B3 there is written 34,540.00 and I want to
show this value exactly in UserForm,

I connected to the textbox2 in UserForm, but my problem is this, it
is showing like this 34540.00 this is not proper format.

it should be 34,540.00 (with comma).

Kindly advise me how fix this problem.

Thanks and regards.

Shahzad
Madinah