Jump to content


Photo

goIndicator? lsHorizontalOnly?


  • Please log in to reply
3 replies to this topic

#1 littlebigfred

littlebigfred
  • Members
  • 176 posts

Posted 13 October 2009 - 04:09 PM

Hello

I have a couple of questions:
  1. What does the goIndicator option do?
  2. Why don't horizontal lines appear in the grid when I set its GridLinesStyle property?


CODE
With NextGrid1 do begin
  Columns.Add(TNxTextColumn,'My Col1');
  Columns.Last.Name := 'col1';

  Columns.Add(TNxTextColumn,'My Col2');
  Columns.Last.Name := 'col2';

  AddRow(1);
  CellsByName['col1',LastAddedRow] := 'test';
  AddRow(1);
  CellsByName['col1',LastAddedRow] := 'test2';

  //What is it?
  Options := Options - [goIndicator];

  //Lines not displayed
  GridLinesStyle := lsHorizontalOnly;
end;


Thank you.

#2 Boki (Berg)

Boki (Berg)

    Boki (Berg)

  • Forum Admin
  • PipPipPipPipPip
  • 8,191 posts
  • Gender:Male

Posted 13 October 2009 - 04:31 PM

Hello Fred,

Indicator indicate currently selected rows and it is located on left side of control. Try to enable it and you will notice it immidiatelly smile.gif

When GridLinesStyle = lsHorizontalOnly only horizontal grid lines are painted. This may give a nice effect.

I hope that this helps smile.gif

Best regards
boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.

#3 littlebigfred

littlebigfred
  • Members
  • 176 posts

Posted 13 October 2009 - 10:26 PM

Hello Boki

I don't display the indicator column, so that's why I wasn't seeing anything.

QUOTE
When GridLinesStyle = lsHorizontalOnly only horizontal grid lines are painted. This may give a nice effect.


I'm not seeing the lines when I do this. Do I need something else?

CODE
procedure TForm1.Button1Click(Sender: TObject);
begin
  With NextGrid1 do begin
    Columns.Add(TNxTextColumn,'My Col1');
    Columns.Last.Name := 'col1';

    Columns.Add(TNxTextColumn,'My Col2');
    Columns.Last.Name := 'col2';

    AddRow(1);
    CellsByName['col1',LastAddedRow] := 'test';

    AddRow(1);
    CellsByName['col2',LastAddedRow] := 'test2';

    //Lines not displayed
    GridLinesStyle := lsHorizontalOnly;
  end;
end;


Thank you.

#4 Boki (Berg)

Boki (Berg)

    Boki (Berg)

  • Forum Admin
  • PipPipPipPipPip
  • 8,191 posts
  • Gender:Male

Posted 14 October 2009 - 12:25 AM

Hello Fred,

You must also to show a grid (goGrid flag to True in Options property). Or right-click on component and pick Show Grid.

I hope that this helps.
boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users