BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

how to programlly add a action to ActionToolbar with ActionM

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi VCL Components Using
View previous topic :: View next topic  
Author Message
ChowVT
Guest





PostPosted: Tue Jul 29, 2003 8:30 pm    Post subject: how to programlly add a action to ActionToolbar with ActionM Reply with quote



how to *programlly* add a action to ActionToolbar with ActionManager?

for it, i did not find any examples in delphi's help and web sites.. etc.
( with delphi, i always feel that delphi(borland)' help is a horror
as for component using examples. is my feeling wrong? )

i wrote the following:
{*******************************************}
unit Unit1;

interface

uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls,
Forms, Dialogs, ToolWin, ActnMan, ActnCtrls, ActnMenus,
XPStyleActnCtrls, ActnList, StdCtrls, Buttons;

type
TForm1 = class(TForm)
procedure BitBtn1Click(Sender: TObject);
private
ActionToolBar1: TActionToolBar;
ActionManager1: TActionManager;
public
constructor Create(AOwner: TComponent); override;
procedure AddAction;
end;

var
Form1: TForm1;

implementation

{$R *.dfm}

{ TForm1 }

constructor TForm1.Create(AOwner: TComponent);
begin
inherited;
ActionManager1:= TActionManager.Create(Self);
ActionToolBar1:= TActionToolBar.Create(Self);
ActionToolBar1.ActionManager:= ActionManager1;
end;

procedure TForm1.AddAction;
// var
// vAction: TAction;
// begin
// vAction:= TAction.Create(Self);
// vAction.Name:= 'Item1';
// vAction.Caption:= 'Item1';

{ ? }

end;

end.
{*******************************************}

in '?', what do i do?

thank for your helps.






Back to top
Steve Trefethen (Borland)
Guest





PostPosted: Tue Jul 29, 2003 9:32 pm    Post subject: Re: how to programlly add a action to ActionToolbar with Act Reply with quote



Quote:
how to *programlly* add a action to ActionToolbar with ActionManager?

The last posting to my website is titled "Using Dynamcially Created Actions
with ActionBands". See the link to my website below.

--
-Steve
C# Builder/Delphi R&D
Borland Software Corporation
My website: http://www.geocities.com/delphihelp
Save time search first: http://groups.google.com
ActionBand FAQ: http://www.geocities.com/delphihelp/info/ABFAQ.htm
How to Ask Questions the Smart Way: http://tinyurl.com/7r35



Back to top
Ignacio Vazquez
Guest





PostPosted: Wed Jul 30, 2003 12:01 am    Post subject: Re: how to programlly add a action to ActionToolbar with Act Reply with quote



"ChowVT" <Chowvt (AT) yahoo (DOT) com.spam.no> wrote

Quote:
without this additional action of user, how to programlly add a action to
action toolbar with action-manager ?

You did look at the posting that Steve mentioned, right?

Cheers,
Ignacio



Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi VCL Components Using All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.