View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Rick Rothstein Rick Rothstein is offline
external usenet poster
 
Posts: 5,934
Default Convert text to Long

myval = CLng(TextBox1.Value) + CLng(TextBox2.Value)
TextBox3.Value = Left(myval, Len(myval) - 3) & "," & Right(myval, 3)


That last line can be made simpler using the Format function...

TextBox3.Value = Format(myval, "0,000")

--
Rick (MVP - Excel)