'Imports System.Runtime.InteropServices

'Structure NJFRect
'    Public Left As Int32
'    Public Top As Int32
'    Public Right As Int32
'    Public Bottom As Int32
'End Structure

Imports NJFVtlib

Public Class Form1

    Private _vtlib As Vtlib
    Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)

    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Dim r As NJFRect
        '_vtlib.VTMShowPicture(0, 0, "resource\b.jpg", r)
        'Exit Sub
        _vtlib.VTMShowFormatText("abc=张三,性别=女", 0, 0, 128, 0)
        Sleep(1000)
        _vtlib.VTMCls(0)
        Sleep(1000)
        _vtlib.VTMPrintText(3, 2, 3, 478, "你好")
        Sleep(1000)
        _vtlib.VTMShowFormatText("姓名=张三,性别=女", 0, 0, 0, 0)
        Sleep(1000)
        _vtlib.NJFSoundOut("1234.5_P")
        Sleep(1000)
        'r.Left = 100
        'r.Right = 300
        'r.Top = 0
        'r.Bottom = 200
        '_vtlib.VTMShowPicture(0, 0, "resource\wish.jpg", r)
        'Sleep(1000)
        '_vtlib.VTMShowPhoto("resource\b.jpg")
        'Sleep(1000)
        'Vtlib.VTMShowPicture(0, 0, "D:\NJF\resource\b.jpg", r)
        _vtlib.VTMAskforCommentEx("001", "resource\a.jpg", "请评价啊", "请评价啊Title", 5, 10000)
        'MsgBox("OK")
    End Sub

    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
        Dim c As Int32
        c = _vtlib.VTMGetComment("001")
        MsgBox(c)
    End Sub

    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        _vtlib = New Vtlib()
    End Sub

    Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
        _vtlib.VTMShowFormatText("abc=张三,性别=女,卡号=12345678,OKOK=第四行,HAHAHA=第五回", 0, 0, 128, 0)
    End Sub

    Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
        _vtlib.VTMCls(0)
        'Sleep(100)
        _vtlib.VTMShowFormatText("abc=张三,性别=女,卡号=12345OK", 0, 0, 128, 0)
    End Sub
End Class
