EvaluationNotebook
gives the notebook in which this function is being evaluated.
Examples
open allclose allBasic Examples (1)
Get the current NotebookObject notebook being evaluated:
Applications (1)
Properties & Relations (2)
The notebook that starts an evaluation might not be the input notebook:
ScheduledTask evaluations have no evaluation notebook and return $Failed:
Text
Wolfram Research (1996), EvaluationNotebook, Wolfram Language function, https://reference.wolfram.com/language/ref/EvaluationNotebook.html.
CMS
Wolfram Language. 1996. "EvaluationNotebook." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/EvaluationNotebook.html.
APA
Wolfram Language. (1996). EvaluationNotebook. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/EvaluationNotebook.html