如何在vb中往串列埠傳送一組十六進位制的資料

私人小組command1_click()尺寸b()位元組,s作為字串'b到序列的頭髮是一個位元組陣列b=strconv(右(串(6,0)和十六進位制(文字),6),vbfromunicode)驗證對於i=0要ubound函式(二)s=s&十六進位制(b(i))debug.print小號以下是減少=格式(val(“&h”,vbunicodestrconv(

  私人小組command1_click()

  尺寸b()位元組,s作為字串

  ’b到序列的頭髮是一個位元組陣列

  b = strconv(右(串(6,0)和十六進位制(文字),6),vbfromunicode)

  驗證對於i = 0要ubound函式(二)s = s&十六進位制(b(i))

  debug.print小號

  以下是減少

  =格式(val(“&h”,vbunicode strconv(b)) ,

  debug.print小號

  end sub

  私人小組form_load()

  文字1。文字字串(“0”))=“ 000042end sub

  尺寸b command1_click()()個位元組,s為一個字串’b的序列頭髮是一個位元組陣列

  b = strconv(右(字串(6 0)和十六進位制(文字),6),vbfromunicode)

  驗證對於i = 0 ubound函式(二)s = s&十六進位制(b(i))

  debug.print小號

  減少=格式(val(“&h”,:vbunicode strconv(b)),

  debug.print小號

  end sub

  私人小組form_load()文字中的文字字串(“0”))= 000042

  end sub

  dim sendhex as string

  sendhex = “ee ” & hex(a1) & ” ” & hex(a2) & ” ” & hex(a3)