View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Arne Hegefors Arne Hegefors is offline
external usenet poster
 
Posts: 244
Default number of decimals

Hi! I have a userform attached to a macro. when the macro runs the user can
see how much of the process has been made. I show this in percentage form.
However I do not know how to adjust the number of decimals so now it looks
like this: Completion: 11,23652357754356%. Needless to say it does not look
good. Can anyone help me with this please?

Here I calculate the percentage:
.Caption2 = "Process completion: " & CStr((pos / lngListLength)) * 100 & "
% "

and in a class module i set properties:
Property Let Caption2(strCaption As String)
frmProgress.lblMsg2.Caption = strCaption
DoEvents
End Property

please help me! any help appreciated! thanks alot