I have a TileList I manually load from data. The routine (slightly simplified) is below. The Tilelist is a 3 x 4layout, so 12 per page. It all works well until the 9th tile is complete. The aHeading argument then changes. It starts off equal to 'Metals'. After the 9th tile it is NOTES and then it is equal to the value of my Datastring. Any ideas?
LoadFromDataset(const aHeading, aTileStyle: string);
var tl: TTMSFMXTile;
begin
TMSFMXTileList1.Tiles.Clear;
TMSFMXTileList1.BeginUpdate;
try
while not FData.Eof do
begin
tl := TMSFMXTileList1.Tiles.Add;
tl.DataString := FData.DataString;
if FData.TileType <> '9' then //property
tl.StyleLookup := aTileStyle
else //is object
begin
if FData.IMAGE.IsNull then
tl.StyleLookup := 'defaulttile'
else
tl.StyleLookup := 'ObjectTile';
end;
tl.Caption := FData.CAPTION;
tl.Notes := FData.NOTES;
FData.Next;
end;
TMSFMXTileList1.PageIndex := 0;
Page1.Header := aHeading;
finally
TMSFMXTileList1.EndUpdate;
TMSFMXTileList1.NeedStyleLookup;
TMSFMXTileList1.ApplyStyleLookup;
end;
end;
Hi,
Did you add the tile custom styles at designtime, and edited the custom style of the TTMSFMXTileList ?
Can you simplify this even more, remove the dataset and load some random data to reproduce the issue?
If the issue is reproducible, can you send us a sample that demonstrates this?
Kind Regards,
Pieter