Delphi窗体的宽度高度与VB窗体的宽度高度的数值转换
GXCGG 2010-02-17 01:39:09 我有一段Delphi代码:
if VSTPlugInfo.hasEditor then
begin
if VSTPlugInfo.editorHeight = 0 then
FVSTForm.ClientHeight := 150
else FVSTForm.ClientHeight := VSTPlugInfo.editorHeight;
if VSTPlugInfo.editorWidth = 0 then
FVSTForm.ClientWidth := 300
else FVSTForm.ClientWidth := VSTPlugInfo.editorWidth;
将其转换为以下代码在VB6使用
If VSTPlugInfo.hasEditor then
If VSTPlugInfo.editorHeight = 0 then
Form1.Height = 150
Else
Form1.Height = VSTPlugInfo.editorHeight
End If
If VSTPlugInfo.editorWidth = 0 then
Form1.Width = 300
Else
Form1.Width = VSTPlugInfo.editorWidth
End If
End If
转换后可以像原来Delphi那样正常使用.但是使用后窗体大小不能像DelPhi那样显示,且窗体缩的很小很小,要手动调整窗体才行.
到底怎么样才能像原来Delphi那样显示完全,需要转换什么数值?