Как написать в Label (текст) не горизонтально, а вертикально - VB
Формулировка задачи:
Очень нужно!!!
Решение задачи: «Как написать в Label (текст) не горизонтально, а вертикально»
textual
Листинг программы
- Option Explicit
- Private Declare Function CreateFontIndirect Lib "gdi32" Alias "CreateFontIndirectA" (lpLogFont As LOGFONT) As Long
- Private Declare Function SelectObject Lib "gdi32" (ByVal hdc As Long, ByVal hObject As Long) As Long
- Private Type LOGFONT
- lfHeight As Long
- lfWidth As Long
- lfEscapement As Long
- lfOrientation As Long
- lfWeight As Long
- lfItalic As Byte
- lfUnderline As Byte
- lfStrikeOut As Byte
- lfCharSet As Byte
- lfOutPrecision As Byte
- lfClipPrecision As Byte
- lfQuality As Byte
- lfPitchAndFamily As Byte
- lfFaceName(32) As Byte
- End Type
- Private Sub Printing(text1 As String, text2 As String)
- Dim RotateMe As LOGFONT
- Me.Picture1.AutoRedraw = True: Me.Picture2.AutoRedraw = True
- RotateMe.lfEscapement = 2700: RotateMe.lfHeight = -20
- SelectObject Me.Picture1.hdc, CreateFontIndirect(RotateMe)
- SelectObject Me.Picture2.hdc, CreateFontIndirect(RotateMe)
- Me.Picture1.CurrentX = 300: Me.Picture1.CurrentY = Me.Picture1.Height - 700
- Me.Picture2.CurrentX = 300: Me.Picture2.CurrentY = Me.Picture2.Height - 700
- Picture1.Print text1
- Picture2.Print text2
- End Sub
- Private Sub Command1_Click()
- Printing 166, 178
- End Sub
ИИ поможет Вам:
- решить любую задачу по программированию
- объяснить код
- расставить комментарии в коде
- и т.д