I use TeXnicCenter to build my LaTeX documents under Windows 7.

I usually have 3-4 tabs open in TeXnicCenter corresponding to the different sections of my document. To build my document I have to go to the first tab (the index of my file), build, and then go back to the old tab where I was editing (one of the sections).

Is there a smarter way of doing this? I would like a hotkey that just move to the first tab and compile. F5 only compiles the current tab, it is not aware if it is the index or not.


2 Answers 2


You can create a project rather than just working with regular files. Each project has a "main file", so that when you "build the project", it builds the main file, which may be different from the actively selected window/tab.

Start a new project (menu option File > New Project) and specify the main file or change the main file for an existing project (menu option Project > Properties):

enter image description here

Now use the "Build and View Output" Ctrl+F5 rather than the usual "Build and View Current File" Ctrl+Shift+F5.

  • Werner, you’re too kind. ;-) Actually creating a project is the only way for what the OP wants to achieve.
    – Speravir
    Jul 8, 2012 at 17:16

You can also convert a regular TeX input file to a project as follows.

Step 1

Let trash.tex be your regular TeX input file. Open it as shown in the following figure.

enter image description here

Step 2

Choose Project and click Create with active file as main file as follows.

enter image description here

Step 3

Click OK and done!

enter image description here

Now you can TeXify the project with one-click.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.