mdlfunction.bas

来自「VB编写的条码打印控制程序,可使用在ZEBRAZ4M等型号打印机」· BAS 代码 · 共 20 行

BAS
20
字号
Attribute VB_Name = "mdlFunction"
Option Explicit

Public Sub CenterForm(f As Form)

With f
    .Left = (Screen.Width - .Width) / 2
    .Top = (Screen.Height - .Height) / 2
End With
End Sub

Public Sub SetFormPosition(childform As Form, Parentform As Form)

With childform
    .Left = (Parentform.ScaleWidth - .Width) / 2
    .Top = (Parentform.ScaleHeight - .Height) / 2
End With

End Sub

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?