Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: How to call or run a NB file in another NB file?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg90874] Re: How to call or run a NB file in another NB file?
  • From: Bob F <deepyogurt at gmail.com>
  • Date: Sun, 27 Jul 2008 02:32:05 -0400 (EDT)
  • References: <g670o5$s4g$1@smc.vnet.net> <g6c9c3$c0a$1@smc.vnet.net>

On Jul 25, 4:19 am, GS <vokap... at gmail.com> wrote:
> On Jul 23, 3:21 am, "Leo.Chen" <leo.chen... at gmail.com> wrote:
>
> > Hi guys,
>
> > I met a problem, in ABC.nb , I need to run XYZ.nb, is there any
> > function to execute the XYZ.nb in ABC.nb?
>
> > cheers,
>
> > leo
>
> Leo,
>
> Here the command that you need to execute from ABC.nb:
>
> nb=NotebookOpen["path_to_file_XYZ\\XYZ.nb",Visible->True];
> FrontEndExecute[{FrontEndToken[nb,"EvaluateNotebook"]}];
>
> GS

This opens the notebook and runs it, but shows the output in it's
notebook, not the notebook that the command ran in. The impression I
got from Leo's question was that he wanted the output to show in the
first notebook, not the second.

So, Leo, where did you want to see the output appear?

-Bob


  • Prev by Date: Cube root of -1 and 1
  • Next by Date: Method Option
  • Previous by thread: Re: How to call or run a NB file in another NB file?
  • Next by thread: Re: Re: How to call or run a NB file in another NB file?