hi What options/properties should use to show a main from scrolbars when I want to? or always visible in Delphi 2010 The help is as too often useless thanks Pw
+3
A:
@Philippe, you can use the ShowScrollBar function and the HorzScrollBar, VertScrollBar propeties to do this.
check this code
procedure TForm1.FormCreate(Sender: TObject);
begin
HorzScrollBar.Range := 10000; // set the range to an higher number
VertScrollBar.Range := 10000; // set the range to an higher number
ShowScrollBar(Handle,SB_BOTH,True);
end;
RRUZ
2010-06-11 07:08:04
thank you very muchthat solved my problem
Philippe Watel
2010-06-12 15:25:07
A:
If you set AutoScroll = true, they should show up if needed. That is, if any visual component is placed outside of the visible client area.
If you do not have any components 'off-screen', why would you need the scrollbar showing?
Anyway, you can set Horz-/VertScrollBar.Range to anything larger than the clientheight/width, and they will show up.
If you need the scrollbar for something else, you can always drop a TScrollBar component on the form.
Vegar
2010-06-11 09:15:30