Home
Top.Mail.Ru Yandeks.Metrika
Forum: "Main";
Current archive: 2002.01.08;
Download: [xml.tar.bz2];

Down

Frame Find similar branches


Sand Worm   (2001-12-19 14:55) [0]

You can somehow access the components located on the frame created on the same form from the main form. Those. A frame has been created on the form, for example, on Label1, is it possible to change the Caption property of this Label1 from the main form? Frame1.Label1.Caption: = "123"; - falls with mats :-( Help the kettle pliz.



Digitman   (2001-12-19 14:58) [1]

Label1 - sv-in the form, but not the frame. and you need to access it through Form1, and not through Frame1



SergVlad   (2001-12-19 15:13) [2]

This is something new - about the relationship of the form and frame.
For example, the form contains a frame frDBTree, the frame contains a TQuery.
I do this:

with frDBTree do begin
quTree.DatabaseName: = DBName;
pSQL: = TStringList.Create;
pSQL.Add ("SELECT * FROM" + pTbName + "R");
pSQL.Add ("ORDER BY R.NAME");
m_SetView;
m_SetStatus;
tv.ReBuildTree;
end;

And nothing else.



Digitman   (2001-12-19 15:31) [3]

> Sand Worm
I may not understand - are you talking about a TFrame or some kind of panel from a palette, which sometimes is also called a frame? If about TFrame, then
Frame1.Label1.Caption should correctly refer to the b-vu (if Self at this moment = the form to which the frame belongs)



Sand Worm   (2001-12-20 07:03) [4]

Please have the following code:
private
FFrame: TFrame;
end;
was
Form1: TForm1;
implementation
Uses unit2; - This is a frame unit, there is a var Frame: TFrame2;
{$ R * .DFM}
/ Here we create a frame /
procedure TForm1.Button1Click (Sender: TObject);
begin
if FFrame <> nil then FFrame.Free;
FFRame: = TFrame2.Create (Panel1);
FFRame.Parent: = Panel1;
FFRame.Align: = alClient;
end;

procedure TForm1.Button2Click (Sender: TObject);
begin
ShowMessage (Frame.Label1.Caption);
end;

So when you click 2 loaf, of course, after you click the 1 loaf, the program drops out with an exception. Tell me where the dog rummaged pliz. The most interesting thing is that compile everything with a bang, even though this is not an indicator, but still.



Digitman   (2001-12-20 08:06) [5]

and what is Frame in ShowMessage (Frame.Label1.Caption)? Where and how is this variable defined? After all, the link to the copy of the created frame, judging by FFRame: = TFrame2.Create (Panel1) is stored in FFRame, not Frame!




Vitaly   (2001-12-20 09:32) [6]

Can the class description TFrame2?



Pages: 1 whole branch

Forum: "Main";
Current archive: 2002.01.08;
Download: [xml.tar.bz2];

Top









Memory: 0.57 MB
Time: 0.03 c
4-22498
cher_gvf
2001-11-05 20:12
2002.01.08
How do you know if such a process is running?


7-22449
Schummi
2001-09-15 07:45
2002.01.08
Windows Favorites


14-22319
iea
2001-11-02 13:34
2002.01.08
Anyone who wears (l) glasses! The question is not idle


1-22235
DDDeN
2001-12-17 06:47
2002.01.08
Screensaver


14-22403
Burmistroff
2001-11-11 20:13
2002.01.08
Super Delphi Reference -2. Your opinion, please.





afrikaans albanian Arabic armenian azerbaijani basque belarusian bulgarian catalan Chinese (Simplified) Chinese (Traditional) croatian Czech danish Dutch English estonian filipino finnish French
galician georgian German greek haitian Creole hebrew Hindi hungarian icelandic indonesian Irish italian Japanese Korean latvian lithuanian macedonian malay maltese norwegian
persian polish portuguese Romanian russian serbian slovak Slovenian Español swahili Swedish thai turkish Ukrainian urdu vietnamese welsh yiddish bengali bosnian
cebuano Esperanto gujarati hausa hmong igbo javanese kannada khmer lao latin maori marathi mongolian nepali punjabi somali tamil telugu yoruba
zulu
English French German Italian Portuguese Russian Spanish