StrDup Function

   
StrDup Function

Class

Microsoft.VisualBasic.Strings

Syntax

 StrDup(   number,character   ) 
number (required; Integer)

The number of times to duplicate the first character in string

character (required; String, Char, or Object containing a String or Char)

The String or Char whose first character is to be duplicated

Return Value

A String containing the character duplicated the specified number of times

Description

Returns a string that consists of the first character of character duplicated number times

Example

The line:

 MsgBox(StrDup(Number:=5, Character:="ABC")) 

displays "AAAAA" .

VB.NET/VB 6 Differences

The StrDup function is new to VB.NET. It appears in part to be a replacement for the VB 6 String function.

   


VB.Net Language in a Nutshell
VB.NET Language in a Nutshell
ISBN: B00006L54Q
EAN: N/A
Year: 2002
Pages: 503

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net