gv天堂gv无码男同在线,欧美视频你懂的,毛片一级毛片毛片一级一级毛毛片,亚洲黄色视频免费播放,满18岁免费看的尤物视频,日本欧美三级片免费看,亚洲综合伊人影视在线播放

  • 首 頁
  • 采購(gòu)市場(chǎng)
  • 企業(yè)查詢
  • 營(yíng)銷建站
  • 營(yíng)銷推廣
  • 行業(yè)資訊
  • 發(fā)布信息
  • VB 如何圖片時(shí)鐘

    懸賞分:20|
    不是用黑白線條表現(xiàn)出來的。
    三張圖片,一張背景,一張時(shí)針圖片,一張分針圖片。用繪圖的方式也行,把時(shí)針和分針繪到背景圖。做出來再加500分。謝謝,要速度。
    知識(shí)庫(kù)標(biāo)簽: |列兵
    這就給你(VistaClock.rar)。
    為最佳答案評(píng)分?
    100% (1)
    不好 0% (0)
    (目前有 1 個(gè)人評(píng)價(jià))

    其 他 回 答共3條

    1樓

    http://www.codeproject.com/KB/datetime/Desktop_Alarm_Clock.aspx
    http://www.codeproject.com/KB/datetime/Analog_Clock.aspx
    知識(shí)庫(kù)標(biāo)簽: |列兵

    2樓


    '添加一個(gè)timer控件和一個(gè)shape控件,名字都用默認(rèn)的名字,粘貼如下代碼即可
    Option Explicit
    Private cx As Long
    Private cy As Long
    Private R As Long
    Private Const Color1 As Long = &H404040
    Private Const Color2 As Long = &H808080
    Private Const PI As Double = 3.14159265358979
    Private Sub DrawBackGround()
    Me.ScaleMode = 3
    Me.FillStyle = 0
    Me.Height = 5800
    Me.Width = 5800
    cx = 150
    cy = 150
    R = 100
    Me.FillColor = Color1
    Me.Circle (cx, cy), R, Color1
    Me.FillColor = Color2
    Me.Circle (cx, cy), R - 7, Color2
    Me.FillColor = Color1
    Me.Circle (cx, cy), R - 15, Color1
    Dim Cor(1 To 12, 1 To 2) As Long
    Me.FontName = "Arial" '如果這個(gè)字體無效 換換黑體試試,字體需要自己到網(wǎng)上下載
    Me.FontBold = True
    Me.FillColor = Color2
    Me.ForeColor = Color2

    Me.FontSize = 14
    Cor(1, 1) = cx + ((R - 15) * Cos(GetDegree(60)) - 10)
    Cor(1, 2) = cy - ((R - 15) * Sin(GetDegree(60)) + 5)
    Me.CurrentX = Cor(1, 1)
    Me.CurrentY = Cor(1, 2)
    Me.Print "1"

    Me.FontSize = 18
    Cor(2, 1) = cx + ((R - 15) * Cos(GetDegree(30)) - 15)
    Cor(2, 2) = cy - ((R - 15) * Sin(GetDegree(30)) + 10)
    Me.CurrentX = Cor(2, 1)
    Me.CurrentY = Cor(2, 2)
    Me.Print "2"

    Me.FontSize = 22
    Cor(3, 1) = cx + (R - 15) - Me.TextWidth("3")
    Cor(3, 2) = cy - Me.TextHeight("3") / 2
    Me.CurrentX = Cor(3, 1)
    Me.CurrentY = Cor(3, 2)
    Me.Print "3"

    Me.FontSize = 24
    Cor(4, 1) = cx + ((R - 15) * Cos(GetDegree(-30)) - 20)
    Cor(4, 2) = cy - ((R - 15) * Sin(GetDegree(-30)) + 20)
    Me.CurrentX = Cor(4, 1)
    Me.CurrentY = Cor(4, 2)
    Me.Print "4"

    Me.FontSize = 26
    Cor(5, 1) = cx + ((R - 15) * Cos(GetDegree(-60)) - 15)
    Cor(5, 2) = cy - ((R - 15) * Sin(GetDegree(-60)) + 32)
    Me.CurrentX = Cor(5, 1)
    Me.CurrentY = Cor(5, 2)
    Me.Print "5"
    Me.FontSize = 28
    Cor(6, 1) = cx - Me.TextWidth("6") / 2
    Cor(6, 2) = cy + (R - 50)
    Me.CurrentX = Cor(6, 1)
    Me.CurrentY = Cor(6, 2)
    Me.Print "6"

    Me.FontSize = 26
    Cor(7, 1) = cx + ((R - 15) * Cos(GetDegree(-120)))
    Cor(7, 2) = cy - ((R - 15) * Sin(GetDegree(-120)) + 32)
    Me.CurrentX = Cor(7, 1)
    Me.CurrentY = Cor(7, 2)
    Me.Print "7"
    Me.FontSize = 24
    Cor(8, 1) = cx + ((R - 15) * Cos(GetDegree(-150)))
    Cor(8, 2) = cy - ((R - 15) * Sin(GetDegree(-150)) + 25)
    Me.CurrentX = Cor(8, 1)
    Me.CurrentY = Cor(8, 2)
    Me.Print "8"
    Me.FontSize = 22
    Cor(9, 1) = cx - (R - 15)
    Cor(9, 2) = cy - Me.TextHeight("9") / 2
    Me.CurrentX = Cor(9, 1)
    Me.CurrentY = Cor(9, 2)
    Me.Print "9"

    Me.FontSize = 18
    Cor(10, 1) = cx + ((R - 15) * Cos(GetDegree(150)))
    Cor(10, 2) = cy - ((R - 15) * Sin(GetDegree(150)) + 10)
    Me.CurrentX = Cor(10, 1)
    Me.CurrentY = Cor(10, 2)
    Me.Print "10"

    Me.FontSize = 14
    Cor(11, 1) = cx + ((R - 15) * Cos(GetDegree(120)))
    Cor(11, 2) = cy - ((R - 15) * Sin(GetDegree(120)) + 5)
    Me.CurrentX = Cor(11, 1)
    Me.CurrentY = Cor(11, 2)
    Me.Print "11"

    Me.FontSize = 10
    Cor(12, 1) = cx - 5
    Cor(12, 2) = cy - (R - 15)
    Me.CurrentX = Cor(12, 1)
    Me.CurrentY = Cor(12, 2)
    Me.Print "12"

    Me.FillColor = Color2
    Dim i As Long
    For i = 0 To 360 Step 30
    Me.Circle ((R - 3) * Cos(GetDegree(i)) + cx, cy - (R - 3) * Sin(GetDegree(i))), 2
    Next i
    End Sub
    Private Sub DrawTime(NowTime As Date)
    Dim h As Long, m As Long, s As Long
    h = Hour(NowTime)
    m = Minute(NowTime)
    s = Second(NowTime)
    'Line (cx, cy)-((R - 30) * Sin(GetDegree(s / 60 * 360)) + cx, cy - (R - 30) * Cos(GetDegree(s / 60 * 360))), vbYellow
    Shape1.Shape = 4
    Shape1.BorderColor = vbYellow
    Shape1.Width = 25
    Shape1.Height = 15
    Shape1.BorderWidth = 1
    Shape1.Left = cx + 35
    Shape1.Top = cy - 8
    Me.CurrentX = Shape1.Left + 2
    Me.CurrentY = Shape1.Top
    Me.ForeColor = vbWhite

    FillColor = vbYellow
    FillStyle = vbSolid

    If h >= 12 Then
    Me.Print "PM"
    Else
    Me.Print "AM"
    End If
    Circle ((R - 20) * Sin(GetDegree(s / 60 * 360)) + cx, cy - (R - 20) * Cos(GetDegree(s / 60 * 360))), 80, vbYellow, -GetDegree((((60 - s) / 60 * 360) + 267) Mod 360), -GetDegree((((60 - s) / 60 * 360) + 273) Mod 360)
    Circle ((R - 40) * Sin(GetDegree(m / 60 * 360)) + cx, cy - (R - 40) * Cos(GetDegree(m / 60 * 360))), 60, vbYellow, -GetDegree((((60 - m) / 60 * 360) + 267) Mod 360), -GetDegree((((60 - m) / 60 * 360) + 273) Mod 360)
    Circle ((R - 60) * Sin(GetDegree(h / 60 * 360)) + cx, cy - (R - 60) * Cos(GetDegree(h / 60 * 360))), 40, vbYellow, -GetDegree((((60 - h) / 60 * 360) + 267) Mod 360), -GetDegree((((60 - h) / 60 * 360) + 273) Mod 360)
    Circle (cx, cy), 5, vbYellow
    End Sub
    Private Function GetDegree(ByVal V As Long) As Double
    GetDegree = V / 360 * 2 * PI
    End Function
    Private Sub Form_Load()
    Timer1.Interval = 1000
    Call Timer1_Timer
    End Sub
    Private Sub Timer1_Timer()
    Me.Cls
    DrawBackGround
    DrawTime Now
    End Sub
    知識(shí)庫(kù)標(biāo)簽: |列兵

    我來回答這個(gè)問題

    立即登陸回答獲取會(huì)員積分,提高用戶級(jí)別
    友情鏈接:
    Copyright © 商名網(wǎng) All Rights Reserved.