[syslinux] Menu system exit
Aaron McSorley
aaron.mcsorley at amd.com
Fri May 21 08:39:21 PDT 2004
I cant get this to work, it still exits to the boot prompt.
Does it make a difference that I'm using pxelinux?
Here is the end of mymenu.c:
add_item("Exit this menu","Go back to Main Menu",OPT_EXITMENU,"mainmenu.com",0);
curr = showmenus(MAIN);
if (curr)
{
if (curr->action == OPT_EXIT) runcommand(curr->data);
if (curr->action == OPT_RUN)
{
if (syslinux) runcommand(curr->data);
else csprint(curr->data,0x07);
return 1;
}
csprint("Error in programming!",0x07);
}
return 0;
I can run mainmenu.com from the boot prompt so, I know that works.
Thanks for your help
-Aaron
On Thu, 20 May 2004, ganapathy murali krishnan wrote:
> If you look at your mymenu.c, there is a line which goes like
>
> "if (curr->action ==OPT_EXIT) return 0"
>
> You could just replace it with
>
> if (curr->action == OPT_EXIT) runcommand(curr->data)
>
> where the curr->data has the name of .com file to execute.
>
> - Murali
>
> Aaron McSorley wrote:
>
> > I want to make a menu system consisting of multiple
> >comboot menu files, how do tell the exit (ESC, Left Arrow) function
> >to go to a menu file rather than the boot prompt.
> >
> >Thanks
> > -Aaron
> >
> >
More information about the Syslinux
mailing list