StringSubstr
Posted by Mohammad Rahhal, Last modified by Diana Alkouni on 14 September 2020 01:00 PM

Syntax

Public Function StringSubstr(stringVar As String, startPos As Integer, Optional Strlengh As Integer = -1) As String

Description

This function is used to return a substring from a text starting from the specific position.

Parameters

Key Description 
stringVar String value to get substring from it.
startPos Start position to get a substring,value of type Integer.
Strlengh length of an extracted substring. If parameter value is -1 this mean the sub string will extract from the specific position to the string end.

Return value

Returns a sub string.

Sample

 Public Sub main()
 Dim x
 x ="3457"
 AlertMessage StringSubstr(CSTR(x),Cint(2)) 'Alert Message will return 457
 End Sub

See Also



Back to VTL Client Script Index

(0 vote(s))
Helpful
Not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments:
CAPTCHA Verification 
 
Please enter the text you see in the image into the textbox below (we use this to prevent automated submissions).

Help Desk Software by Hybrid Solutions