|
VB 4/6- und VBA-Forum - Beitragsübersicht - |
|
Thema | VB6: Mein Text auf dem Desktop |
Von |
Thomas |
Datum |
21. Oktober 2017 um 17:31:25 |
Frage |
Hallo,wie kann ich einen Text zb.Hallo Thomas am Destop anzeigen lassen ?Gruß Thomas |
|
Antwort: |
Von |
Rippler |
Datum |
22. Oktober 2017 um 02:58:05 |
Antwort |
Private Declare Function GetDesktopWindow Lib "user32" () As Long Private Declare Function GetWindowDC Lib "user32" (ByVal hwnd As Long) As Long Private Declare Function TextOut Lib "gdi32" Alias "TextOutA" _ (ByVal hdc As Long, ByVal x As Long, ByVal y As Long, ByVal lpString As String, _ ByVal nCount As Long) As Long
Public Function WindowText(dblX As Double, dblY As Double, strText As String, dblTxt As Double) TextOut GetWindowDC(GetDesktopWindow), dblX, dblY, strText, dblTxt End Function
Private Sub Command1_Click() Dim str As String str = "Hallo Thomas" Call WindowText(400, 400, str, Len(str)) End Sub |
|
[ Antwort schreiben | Zurück zum VB 4/6- und VBA-Forum | Forum-Hilfe ] |
|
Letzte Aktualisierung: Sonntag, 13. Dezember 2015 |
|