Topic: Style?? (2)
I just found out that using the Style option from the menu to have a nicer theme in you're software, the Autoscrol doesn't work. Realy now?? This sucks...except if someone knows a way to fix it...your her please....
My Visual Database → General → Style?? (2)
I just found out that using the Style option from the menu to have a nicer theme in you're software, the Autoscrol doesn't work. Realy now?? This sucks...except if someone knows a way to fix it...your her please....
You are great!!!!!! thank you
I have used the code but when I enable the autoscroll and the Windows State is maximized the scroll bar in horizontal exist but in vertical it is missing. Can you please help me?
The code is absolutely working, both scrollbars appear, including in the window maximization mode.
Yes you have right I found my error it works perfect. Thanks
I have added the following code in my program the script in the attached link
http://myvisualdatabase.com/forum/viewt … 335#p45335
i found it out when I press the Tab key to continue to the next text box. The "funny thing" is the holding the shift + tab it works ok but this is not normal
But it has changed all the TabOrder of the Text boxes and the Buttons. Even when I have the order correct in the program the result is not correct. Any idea??
I don't see such an effect. It is possible that the traversal order is changing due to the addition of a scroll area. Please send a test project for analysis and solution.
I don't see such an effect. It is possible that the traversal order is changing due to the addition of a scroll area. Please send a test project for analysis and solution.
Please take a look .
When transferring controls, their taborder changes. I finalized the transfer procedure and added saving the taborder.
procedure AddScrollBox( AForm:TAForm;);
var
SB:TScrollBox;
i: integer;
List:TStringList; // list for storing controls taborder
begin
List := TStringList.Create;
List.Sorted := True;
SB := TScrollBox.Create(AForm);
SB.Parent := AForm;
SB.Align := alClient;
for i := AForm.controlCount - 1 downto 0 do
begin
if AForm.Controls[i] <> SB then
begin
// for window controls remember their taborder
if AForm.Controls[i] is TWinControl then
List.AddObject( IntToStr( WinControl_GetTabOrder( TWinControl(AForm.Controls[i]) ) ), AForm.Controls[i] );
AForm.Controls[i].Parent := SB;
end;
end;
// restoring the taborder
for i := 0 to List.Count - 1 do
begin
WinControl_SetTabOrder(TWinControl( List.Objects(i) ), StrToInt( List.Strings(i) ) );
end;
List.Free;
end;
// since in My Visual Database for window controls forgot to implement the taborder property,
// we need two auxiliary functions that need to be supplemented with all the visual components used in the project
function WinControl_GetTabOrder(AWinControl:TWinControl):integer;
begin
if AWinControl is TdbButton then
result := TdbButton(AWinControl).TabOrder
else
if AWinControl is TdbEdit then
result := TdbEdit(AWinControl).TabOrder
end;
procedure WinControl_SetTabOrder(AWinControl:TWinControl; ATabOrder:integer);
begin
if AWinControl is TdbButton then
TdbButton(AWinControl).TabOrder := ATabOrder
else
if AWinControl is TdbEdit then
TdbEdit(AWinControl).TabOrder := ATabOrder;
end;
k245 thank you for helping me. it works about 50%. What I wonna say is that it works for some buttons and then it works again random thebtab order
I have insert your script and fixed again all the tab orders and failed, and all this is because selecting style all the forms do not have the autoscroll function even if we select it from the tool bar or insert it l as a script.
As I wrote in a comment in the script, the WinControl_GetTabOrder() and WinControl_SetTabOrder() procedures need to be improved: they need to be written in ALL visual components that have the taborder property. I hope you can do this part of the work yourself.
As I wrote in a comment in the script, the WinControl_GetTabOrder() and WinControl_SetTabOrder() procedures need to be improved: they need to be written in ALL visual components that have the taborder property. I hope you can do this part of the work yourself.
What do you mean " they need to be written in ALL visual components that have the taborder property." ???
Thank you for your help
if AWinControl is TdbButton then
TdbButton(AWinControl).TabOrder := ATabOrder
else
if AWinControl is TdbEdit then
TdbEdit(AWinControl).TabOrder := ATabOrder
else
if ...
TdbMemo
TdbCheckBox
TdbDateTimePicker
and ...
if AWinControl is TdbButton then TdbButton(AWinControl).TabOrder := ATabOrder else if AWinControl is TdbEdit then TdbEdit(AWinControl).TabOrder := ATabOrder else if ...
TdbMemo
TdbCheckBox
TdbDateTimePicker
and ...
Аbsolutely right!
Thank you all so much!!!
My Visual Database → General → Style?? (2)
Powered by PunBB, supported by Informer Technologies, Inc.
Theme Hydrogen by Kushi