Templates, Wizards & ToolsInverse search with Sumatra PDF

Information and discussion about TeXnicCenter document/project templates and wizards and other tools and extensions for TeXnicCenter
Post Reply
aragami
Posts: 5
Joined: Sun Sep 19, 2010 4:23 pm

Inverse search with Sumatra PDF

Post by aragami »

Hi,

I use texniccenter with sumatrapdf.
Problem: When performing inverse search, always a new instance of tecniccenter is opened. Apart from this, the integration works properly.

Configuration
Windows 7 (my last configuration with XP worked fine)
texniccenter 2 alpha 3,
Miktex 2.8,
SumatraPDF 1.1

Used Command:
C:\Programme\SumatraPDF\SumatraPDF.exe -inverse-search "\"C:\Programme\TeXnicCenter Alpha\teXniCcenter.EXE\" /ddecmd \"[goto('%f','%l')]'\""

Many thanks

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
Sergiu
Posts: 63
Joined: Mon May 12, 2008 1:21 pm

Inverse search with Sumatra PDF

Post by Sergiu »

This is a bug in alpha 3 which has been already fixed. To make inverse search work again remove the apostrophe behind the last square bracket, i.e. use

Code: Select all

-inverse-search "\"C:\Programme\TeXnicCenter Alpha\teXniCcenter.EXE\" /ddecmd \"[goto('%f','%l')]\""
as Sumatra PDF command-line arguments. Additionally, you may need to reset Sumatra PDF settings.
TeXnicCenter Developer
http://www.texniccenter.org/
aragami
Posts: 5
Joined: Sun Sep 19, 2010 4:23 pm

Inverse search with Sumatra PDF

Post by aragami »

Hi Sergiu,
Many thanks for the immediate response. Unfortunatelly, your hint didn’t help yet. I tried
C:\Programme\SumatraPDF\SumatraPDF.exe -inverse-search "\"C:\Programme\TeXnicCenter Alpha\teXniCcenter.EXE\" /ddecmd \"[goto('%f','%l')]\""
including some "magic" such as restarting texniccenter and sumatrapdf, I checked if the apostrohpe was the correct character (see the well known pdf copy&paste problem).
Maybe your last hint might help, but I do not understand it: What does "reset Sumatra PDF settings" mean?
Many thanks
Sergiu
Posts: 63
Joined: Mon May 12, 2008 1:21 pm

Re: Inverse search with Sumatra PDF

Post by Sergiu »

Just remove sumatrapdfprefs.dat stored in the %AppData%\SumatraPDF directory.
TeXnicCenter Developer
http://www.texniccenter.org/
aragami
Posts: 5
Joined: Sun Sep 19, 2010 4:23 pm

Re: Inverse search with Sumatra PDF

Post by aragami »

Yep. Works! many thanks
Remedy
Posts: 1
Joined: Tue Sep 06, 2011 4:59 pm

Re: Inverse search with Sumatra PDF

Post by Remedy »

Hey!

I have the same problem aragami postet initially. Unfortunatelly your suggestions didn't help.

Forward Search is working fine. For the inverse search sumatra opens a new texniccenter instance just with the .tex-file I was working in at this moment (I'm including several Documentparts with the \include command). In the new instance reverse search works all fine, therefore the forward search doesn't work there. It's the other way arround with the original instance, which is still open.

I googled a lot but couldn't find a satisfying solution so far.

Configuration
Windows 7
texniccenter 2 alpha 3,
Miktex 2.9,
SumatraPDF 1.7

With the command you already posted:
C:\Programme\SumatraPDF\SumatraPDF.exe -inverse-search "\"C:\Programme\TeXnicCenter Alpha\TeXnicCenter.exe\" /ddecmd \"[goto('%f','%l')]\""

Hints i found suggesting to replace the doublequotes with apostrophes didn't help either. Same with resetting Sumatra pdf.

Thx for your help!
Best regards
Remedy
gaddoc
Posts: 1
Joined: Thu Mar 15, 2012 4:42 pm

Re: Inverse search with Sumatra PDF

Post by gaddoc »

I know this thread is rather old, but it was the one that helped me set up inverse search correctly with Sumatra and TeXnicCenter 2.0 alpha 3.

Unfortunatly with updating to TeXnicCenter 2.0 alpha 4 the same behavior returned - doing a inverse search in Sumatra always opens a new instance of TeXnicCenter with just the corresponding TeX file, which i really bugging me.
I tried out all the different Tips, that I found on the net, but did not succede so far.

Did someone make it work? Or Am I the only one with this problem?
Post Reply