Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sprintf function in VB.NET

Status
Not open for further replies.

crystalReporterNew

Programmer
Jan 18, 2004
24
US
Can someone point me out to compiling code for the Sprintf function in VB .NET?

Thanks
 
sprintf() is a C and C++ function, but there's a way to do similar stuff in .NET using the .Format method on the String class:
Code:
  Dim result As String = String.Format("{0} times {0} = {1}", _
      number, number * number)

  MsgBox(result)

Chip H.


If you want to get the best response to a question, please check out FAQ222-2244 first
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top