Left


Definition: Returns a specified number of characters from the left side of a string.

 

What’s that? You want to know if it’s possible to use Windows PowerShell to return the first xcharacters in a string?Of course it is: all you have to do is call the Substringmethod, passing two parameters: the starting character (with 0 being the first character position) and the number of characters to return. For example, this command assigns the letters of the alphabet to a variable named $a, then uses Substring to reassign $a just the first three letters in the string:

 

$a="ABCDEFGHIJKLMNOPQRSTUVWXYZ"
$a = $ a.substring (0,3)

 

When you run this command and then echo back the value of $ a youshould get the following:

 

ABC

 



 

 

 

500 Internal Server Error

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@systemmanager.forsenergy.ru to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.