Hi Darius, thanks for the reply.
> allMenus[i].OnClick:[EMAIL PROTECTED]
Thank you, that worked.
>Not shure what you want to say here. Can you be more specific?
Yes. The menu file is in the form: "Command=Open" and "Command=New". I
need some way of Passing "New" or "Open" to my program once the user has
selected the menu item.
Darius Blaszijk wrote:
I'd like help on 2 linked problems: Firstly my App halts at
"allMenus[i].OnClick:=Form1.MenuItem2Click;" with the error "Wrong
Number of parameters specified."
Procedure MenuItem2Click is in Unit2 and is in the form "procedure
TForm1.MenuItem2Click(Sender: TObject);" I understand, from Googling
extensively, that this should work.
It should yes, but from what I can see you should use:
allMenus[i].OnClick:[EMAIL PROTECTED] or add {$mode delphi} to the top
of your unit. FPC has more strict syntax than delphi.
And secondly, how can I access the Command=new Name/Value pair once
it does get to MenuItem2Click.....
Not shure what you want to say here. Can you be more specific?
Darius
I hope this is reasonably clear.
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives
--
Dave Coventry
Tel: +27(0)31 3092301
Fax: +27(0)31 3092301
Cell: +27(0)82 3685983
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives