View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
rick rick is offline
external usenet poster
 
Posts: 32
Default How to apply NumberFormat to control on a Userform?

I am having a problem with the display of data in a userform control.

The control is a textbox. I have set it's controlsource with:
Me("ProjectNumber").ControlSource =
..Range("Project_Number").Address(external:=True)
which refers to a sheet cell formatted with a Custom "000000". On the sheet
the value shows correctly (000123)
but in the Userform it displays as (123).

Is there a way to get the Userform control's numberformat set? I have tried:
Me("ProjectNumber").NumberFormat = "000000" but this results in a runtime
error "438 - Object does not support this property or method."

Thanks for your wisdom.

.... rick