Topic: Scroll Bar

Hi every one,
                   On tablegrid if we move horizontal scroll bar then columns move also. Is there a way where any selected column does not move while moving horizontal scroll bar.

Re: Scroll Bar

Hi,
You can fix columns from the left of the tablegrid if that's what you mean.
Have a look at the example where you can choose the number of columns you want to fix.
Derek.

Post's attachments

Attachment icon fix columns.zip 349.66 kb, 167 downloads since 2022-03-25 

Re: Scroll Bar

Thank you derek. That is what I want but you can explain strtoint64 in this statement?

procedure Form1_Edit1_OnChange (Sender: TObject);
begin
  if form1.edit1.Value > 0 then form1.tablegrid1.FixedCols := strtoint64(form1.edit1.text) else form1.tablegrid1.FixedCols := 0;
end;

Re: Scroll Bar

Hello Derek, Hello unforgettable

StrToInt64 converts the string S to a Int64 value, and returns this value.
The string can only contain numerical characters, and optionally a minus sign as the first character. Whitespace is not allowed.

Hexadecimal values (starting with the $ character) are supported.
For example, IntegerString such as '123' into an Int64 return value.

It supports +ve and -ve numbers, and hexadecimal numbers, as prefixed by $ or 0x.

JB

Re: Scroll Bar

Thank you jb to explain but I could not understand why here is 64? why it is not 65 or 66 or any other?

Re: Scroll Bar

Please read.


http://www.delphibasics.co.uk/ByFunctio … p;Sub=Ints

Re: Scroll Bar

Hello unforgettable, hello sparrow

it is an integer coded on 64-bit which is currently the maximum size in Delphi language (turbo pascal)
JB

Re: Scroll Bar

Thank you jb.