Page 1 of 1

Problem with a Chart disappearing

Posted: Thu Jul 20, 2006 12:10 pm
by 9346270
Hi again,

Got another problem. When attempting to make a graph "full view" (ie. on another form in a bigger state) the previous "thumbnail" of the graph is disappearing. Here is the code:

procedure TfrMain.FullviewClick(Sender: TObject);
begin
frMain.Hide;
GraphName := PopupMenuGraph.PopupComponent.Name;
For Search := 1 to 40 do
Begin
If GraphName = Graph[Search].Name then
Begin
Found := Search;
Break;
end;
end;
Tmp[2] := Graph[Found];
Tmp[2].Name := 'FullviewGraph';
frFullview.Fullview := Tmp[2];
frFullview.Fullview.Parent := frFullview;
frFullview.Fullview.Height := 497;
frFullview.Fullview.Width := 793;
frFullview.Fullview.Left := 16;
frFullview.Fullview.Top := 16;
frFullview.Show;
end;

As you can see, the "thumbnail" of the graph is stored in Graph[Found]. Tmp[2] then copies Graph[Found]. Tmp[2] is loaded to a TChart on another form. When frFullview is hidden again and frMain is shown, the Chart found in Graph[Found] has disappeared and a blank space is left.

What i dont understand is where it has gone? :(

Thanks for the help.

Regards
Justin

Posted: Thu Jul 20, 2006 12:49 pm
by narcis
Hi Justin,

Could you please send us an example project we can run "as-is" to reproduce the problem here?

You can post your files at news://www.steema.net/steema.public.attachments newsgroup.

Thanks in advance.