Group Abstract Group Abstract

Message Boards Message Boards

0
|
6K Views
|
7 Replies
|
3 Total Likes
View groups...
Share
Share this post:

Open notebook in current window

Posted 2 years ago

Is it possible to open a notebook in the current window?

This code opens the notebook in a new window but I want to reuse the window of the current notebook.

NotebookOpen[(*path to notebook*)]
POSTED BY: Azer Bajdzan
7 Replies
POSTED BY: Jack I Houng
POSTED BY: Gareth Russell
Posted 2 years ago

You understand my question the right way. Or I can describe it by a web browser. You can open a link in a new window/tab or reuse current window in a web browser. If you open new link in current window and want to save it then the file name changes according to the new link name. Now do the same with notebooks in Mathematica instead of webpages in a web browser. Such a simple task and I wonder why they did not include such an option for NotebookOpen like, say, ReuseWindow->True.

POSTED BY: Azer Bajdzan
Posted 2 years ago

Carl's suggestion on NotebookWrite can well be used. Since data can also be a complete notebook. An example:

Save the following notebook to the default directory ($HomeDirectory) and give it the name Example.nb

Then, evaluate this in another notebook:

NotebookWrite[EvaluationNotebook[], Import["Example.nb"]]
POSTED BY: Hans Milton
Posted 2 years ago
POSTED BY: Azer Bajdzan

See the Wolfram documentation for NotebookWrite.

POSTED BY: Carl Verdon
Posted 2 years ago

NotebookWrite writes data to the current notebook. It does not open particular notebook in the current window.

POSTED BY: Azer Bajdzan
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard