作者:VB.NET开发
项目:Syste
' This example demonstrates the Console.Title property.
Class Sample
Public Shared Sub Main()
Console.WriteLine("The current console title is: ""{0}""", Console.Title)
Console.WriteLine(" (Press any key to change the console title.)")
Console.ReadKey(True)
Console.Title = "The title has changed!"
Console.WriteLine("Note that the new console title is ""{0}""" & vbCrLf & _
" (Press any key to quit.)", Console.Title)
Console.ReadKey(True)
End Sub
End Class
作者:VB程序
项目:Syste
Module Module1
Sub Main()
Console.Title = "Custom Command Window"
Console.BackgroundColor = ConsoleColor.White
Console.ForegroundColor = ConsoleColor.DarkBlue
Console.WindowHeight = Console.LargestWindowHeight - 15
Console.WindowWidth = Console.LargestWindowWidth - 15
'Call a few methods to clear and pause the window.
Console.Clear()
End Sub
End Module