Questions on Notebooks (*.nb, *.ma in earlier versions), structured interactive documents produced by Mathematica that can contain text, graphics, sound, calculations, typeset expressions, and user interface elements.

learn more… | top users | synonyms (1)

5
votes
2answers
122 views

How can I determine the hyperlink of a currently opened documentation page programmatically?

Every pages in the documentation has a hyperlink. Here are some examples: ...
14
votes
2answers
280 views

Automatically close Mathematica

It seems there are a lot of related topics but I haven't found an answer. I want to automatically quit Mathematica after some procedures are done but dialog window appears: ...
2
votes
0answers
80 views

Counter assignments [duplicate]

I'm trying to create a specific outline format to match some course materials I am required to submit in a particular way. I know how to create auto-numbered cells using ...
7
votes
1answer
156 views

How to do computations simultaneously in multiple notebooks? [duplicate]

I have a Mathematica script which takes a few hours to run. I want to be able to open another notebook while it's running and do some other computations. I have enough many cores on my computer for ...
0
votes
2answers
244 views

Creating an API or Widget based on a Mathematica notebook

I'm trying to create a matrix calculator and graph tools for our website and was wondering if there is a way to create Wolfram API or Widgets based on a Mathematica notebook.
32
votes
0answers
498 views

Numbered equations/formulas

How do you number equations in Mathematica notebooks so that they are exported correctly into latex? In case you don't know how to put numbered equations here is quick review. Open a new notebook ...
7
votes
1answer
116 views

After modifying expression, new result doesn't replace old one

After I modify and re-evaluate an expression, the new result doesn't replace the old one. Rather, what happens is that the old result gets pushed down and Mathematica displays the current result at ...
6
votes
1answer
142 views

Unable to save changes in Option Inspector from one session to another for the Documentation Center

I wanted to change the global option "WindowsSize" to the "large" value using the Option Inspector. It works well for the current session. But then I realize the "Apply" button was greyed and not ...
2
votes
1answer
95 views

Hide both input cell and output cell

You can double-click the right gutter of a input cell to hide a corresponding output cell or double-click the gutter of the output cell to hide the input cell. I would like to hide both the input and ...
10
votes
3answers
470 views

Is it possible to insert an animated image into Mathematica notebook?

I find it very convenient to use Mathematica notebooks to organise the codes + results. I was wondering if it is possible to insert an animated image (say an animated gif) in the middle of a ...
4
votes
1answer
105 views
8
votes
2answers
108 views

Alternative to NotebookLocate or NotebookFind

In Mathematica 8.0 and older, there are two ways to select cells based on cell tags. NotebookLocate["CellTag"]; NotebookGet[EvaluationNotebook[]] and ...
18
votes
3answers
2k views

What are the advantages of using .nb rather than .m files?

I can edit a notebook within the mathematica front end and then Save As a .m file, which produces output like this: ...
0
votes
2answers
80 views

Cases Message Valid Notebook Structure

Note: Spelunking will likely be needed. Execute the following. You should get back and error along the lines of First::first:... This error is unimportant except ...
3
votes
1answer
153 views

Disable and Enable Hyperlinks Graphics

I have a Graphics element which I edit with Drawing Tools. I have determined a technique using NotebookWrite to add ...
6
votes
1answer
122 views

How to evaluate an input cell automatically after evaluating the previous one

Is there any way to automatically evaluate an input cell after evaluating the previous one without the need to press ENTER?
3
votes
2answers
98 views

ToBoxes Respect Spaces Code

Is there a way to force either ToBoxes or MakeBoxes to respect the spacing that occurs in the code? For example is there a way ...
2
votes
1answer
66 views

WholeCellGroupOpener and Hyperlinks

My problem is: I would like to activate WholeCellGroupOpener on a cell containing hyperlinks. But when I do that, the hyperlinks are no longer active. Is there a way to change the order of the two, so ...
1
vote
1answer
97 views

Spelling dictionary corrupted

I have a problem with the Check Spelling in Mathematica, that I quite don't understand: If I try to use the Check Spelling on any notebook, the check just stop before the first word and in the field ...
12
votes
0answers
103 views

How to keep the ctrl+shift+k help menu remain in display while typing?

In Mathematica 9, one can type ctrl+shift+k to display menu which has all the possible signatures/definitions for the function or command in question. One can ...
2
votes
1answer
97 views

NotebookWrite undo

Is there way to make NotebookWrites undooable? For example let's say I open a new notebook and then run. ...
7
votes
1answer
127 views

When are EvaluationNotebook[] and ButtonNotebook[] different?

I am looking for a concrete code example where EvaluationNotebook[] and ButtonNotebook[] will return different results. The ...
10
votes
2answers
206 views

how to make cursor jump automatically to next input cell after evaluating previous one?

When making separate cells in order to make separate computations to better see the result of each one before going to the next cell to do the next computation (which is a good way of doing things), ...
0
votes
1answer
151 views

Initialization Cells in CDF

I am wanting to run about 15 pages of initialization cells in a CDF, but can't seem to do so. I have set the InitializationCellEvaluation to True and InitializationCellWarning to False, but it doesn't ...
19
votes
3answers
873 views

How to find pieces of code responsible for syntax errors?

Especially: How to find the piece of code responsible for a missing parenthesis problem caused by a misplaced SuperScriptBox For last 30 minutes (and I was lucky ...
5
votes
1answer
91 views

Replace content of selected cells, each getting different new content

Let's say I select 2 different cells and then attempt to replace their content using NotebookWrite inside a button. How might I replace each cell's content ...
1
vote
1answer
94 views

NotebookWrite Multiple Selected Objects

Lets say I select shapes in a Graphics diagram in the following picture. Generated from the following set of code: ...
49
votes
4answers
2k views

Using the Mathematica front-end efficiently for editing notebooks

Background: I have used Vim for 15+ years. There is a certain "one"-ness with the editor one achieves. Emacs users also experience this. Notepad users do not. My current interaction with the ...
4
votes
1answer
76 views

Why selecting text in my notebook become abnormal?

Selecting text in one of my Notebooks becomes abnormal. Here is the unselected text: and here is the partly selected text: When the text being selected, it should be like this: What is wrong ...
2
votes
1answer
46 views

Prevent Cell Deletion

How might I be able to prevent a Cell form being deleted when you press the Delete key? Maybe there is a way to display some type of ...
2
votes
1answer
49 views

How do I force all Graphics Text to be StandardForm?

I've been playing around for while trying to determine how to get all graphic objects to use StandardForm fonts. That is, I want all axes labelling, titling, legends, inserted text, etc., for 2D/3D ...
11
votes
4answers
2k views

How to change default notebook background color?

How does one change the default notebook background color?
2
votes
1answer
147 views

How to calculate the whole run time in a specific notebook?

I have found a way to show the run time in a specific cell in a notebook (.nb). Now, I want to have the whole run time including all cells in a specific notebook. How is it possible to calculate it ...
0
votes
0answers
41 views

How to syntax highlight a code cell in another language? [duplicate]

I'm learning c/c++/objective-c and I wanted to write my notes in a mathematica notebook. But without the proper syntax color highlighting it looks terrible....
3
votes
0answers
77 views

Make all new cells have a specific style as a function of the Mathematica installation

I would like all new input and output cells, in fact all new cells including section headers and such, to have a specific stylistic property (...
1
vote
0answers
73 views

Notebook output behaving erratically

Normally, when reevaluating a cell, the following output cell is overwritten with the new result. I have a lengthy notebook in which at some point for unknown reasons each reevaluation generates a new ...
0
votes
1answer
73 views

How to pop out of a subsection in a notebook

Let's say I have a section in a notebook, which I begin with a cmd-4 keystroke. I type in some text and expressions, and now I want to introduce a subsection for ...
3
votes
2answers
146 views

How can I change the highlighting color of an InlineMathCell?

When using the InlineMathCell one types Ctrl+9 within the text cell, and gets a slot for starting typing the InlineMathCell part. When typing the content of the InlineMathCell is slightly highlighted ...
6
votes
0answers
114 views

How to convert a notebook cell to a string retaining all formatting, colorization of identifiers etc?

I have an opened Mathematica notebook containing several cells. Suppose, I am interested in one of them -- it may contain a complete or incomplete expression (e.g. with syntax errors, highlighted ...
1
vote
0answers
79 views

Remote access to notebook is very slow

I am using Mathematica at work remotely from a computer in my building and I can edit notebooks by opening them from terminal via ssh without problem (a little slow if there is a figure with many ...
16
votes
1answer
270 views

How does the built-in debugger decide what to highlight?

How does the built-in debugger decide which definition to highlight in the notebook when Break on messages" is enabled? Here's an example to illustrate what I mean. First, enable the debugger ...
4
votes
2answers
184 views

Adapting “Find and Replace” functionality to work with Patterns

I was thinking if there is something like Find and Replace (Crtl+F) functionality adapted to work with patterns. Probably not, but it seems possible to create this with some effort and skills in ...
1
vote
1answer
199 views

Why isn't autosave enabled by default? [closed]

While I've come across several ways to implement/enable autosave (see: Is there a notebook autosave frequency configuration?, Saving my code before cell evaluations: Insurance against front end ...
1
vote
1answer
100 views

Is it possible to create a styled cell with pre-defined content?

When you create a new styled notebook from the Stylesheets chooser dialag, you get a new notebook using the chosen style with some sample content provided. But if you apply styles from the same ...
13
votes
2answers
1k views

Relative paths for portable notebooks in Mathematica

I cannot find how to use relative paths in Mathematica. My directory structure is simple. ...
0
votes
1answer
80 views

Evaluation of notebook from chosen cell to end

There is option to evaluate the complete notebook but I wanted to know if its possible to evaluate notebook from some desired cell to end or some other desired cell following?
5
votes
1answer
89 views

ClearAll[“Global`*”] stops working with Context set to 'unique to this Notebook'

I just changed my default notebook context to 'unique to this Notebook' so that variables don't roll across numerous open notebooks. Doing this, however, made the command ClearAll["Global*"] stop ...
3
votes
2answers
834 views

Taking class notes with a Mathematica Notebook

Dose anyone take notes in a technical class using a Mathematica notebook? If anyone does, how does it compare to paper and are there useful commands? I have a hard time remembering ctrl/alt/esc ...
2
votes
0answers
54 views

How to retroactively merge cell change history according to a merge interval

I recently noted that there is an option in the options inspector to set a merge interval for cell changes. This (I think) prevents a quick series of changes from spamming your notebook history with a ...
3
votes
1answer
96 views

How to replace a string within a selected region in a notebook?

I want to replace a string in a selected region/cell in mathematica notebook/package. I searched but didn' t get any result. I think it' s a quite common feature for editors/programming environments. ...