DELPHI 怎么加载模版 在窗体内打开网页 网页随窗体的大小而自动改变 窗体随屏幕的大小而自动改变
怎么加载模版在窗体内打开网页网页随窗体的大小而自动改变窗体随屏幕的大小而自动改变VB源代码PrivateSubForm_Load()Me.Width=0.8*VB.Scr...
怎么加载模版 在窗体内打开网页 网页随窗体的大小而自动改变
窗体随屏幕的大小而自动改变
VB 源代码
Private Sub Form_Load()
Me.Width = 0.8 * VB.Screen.Width
Me.Height = 0.8 * VB.Screen.Height WebBrowser1.Navigate "URL"
Skin1.ApplySkin Me.hWnd
End Sub Private Sub Form_Resize()
WebBrowser1.Top = 0
WebBrowser1.Left = 0
WebBrowser1.Height = Me.Height - 80
WebBrowser1.Width = Me.Width - 80
End Sub 展开
窗体随屏幕的大小而自动改变
VB 源代码
Private Sub Form_Load()
Me.Width = 0.8 * VB.Screen.Width
Me.Height = 0.8 * VB.Screen.Height WebBrowser1.Navigate "URL"
Skin1.ApplySkin Me.hWnd
End Sub Private Sub Form_Resize()
WebBrowser1.Top = 0
WebBrowser1.Left = 0
WebBrowser1.Height = Me.Height - 80
WebBrowser1.Width = Me.Width - 80
End Sub 展开
3个回答
展开全部
Delphi一样的。帮你改成Delphi了,你参考下。
procedure TForm1.FormCreate(Sender: TObject);
begin
self.Width := round(0.8 * screen.Width);
self.Height := round(0.8 * screen.Height);
end;
procedure TForm1.FormResize(Sender: TObject);
begin
WebBrowser1.Top := 0;
WebBrowser1.Left := 0;
WebBrowser1.Height := self.Height - 80;
WebBrowser1.Width := self.Width - 80;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
self.Width := round(0.8 * screen.Width);
self.Height := round(0.8 * screen.Height);
end;
procedure TForm1.FormResize(Sender: TObject);
begin
WebBrowser1.Top := 0;
WebBrowser1.Left := 0;
WebBrowser1.Height := self.Height - 80;
WebBrowser1.Width := self.Width - 80;
end;
展开全部
Width := 0.8 * Screen.Width;
Height := 0.8 * Screen.Height ;
WebBrowser1.Navigate:=‘url’;
WebBrowser1.Top := 0;
WebBrowser1.Left := 0;
WebBrowser1.Height := Height - 80;
WebBrowser1.Width ;= Width - 80;
Height := 0.8 * Screen.Height ;
WebBrowser1.Navigate:=‘url’;
WebBrowser1.Top := 0;
WebBrowser1.Left := 0;
WebBrowser1.Height := Height - 80;
WebBrowser1.Width ;= Width - 80;
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
procedure TForm1.FormCreate(Sender: TObject);
begin
self.Width := round(0.8 * screen.Width);
self.Height := round(0.8 * screen.Height);
end;
procedure TForm1.FormResize(Sender: TObject);
begin
WebBrowser1.Top := 0;
WebBrowser1.Left := 0;
WebBrowser1.Height := self.Height - 80;
WebBrowser1.Width := self.Width - 80;
end;
begin
self.Width := round(0.8 * screen.Width);
self.Height := round(0.8 * screen.Height);
end;
procedure TForm1.FormResize(Sender: TObject);
begin
WebBrowser1.Top := 0;
WebBrowser1.Left := 0;
WebBrowser1.Height := self.Height - 80;
WebBrowser1.Width := self.Width - 80;
end;
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询