[Tex/LaTex] Standalone convert does not produce png

pngstandalone

I have the following example code:

\documentclass[convert={convertexe={convert.exe}}]{standalone}

\begin{document}

 hello

\end{document}

The addition of "convert={convertexe={convert.exe}}" is added as suggested here. I want to convert the outcome into a .png file.

I use the following command

pdflatex --shell-escape Test.tex

as suggested in the standalone package manual section 4.6.2.

But then I get the following error message:

runsystem(pdflatex  -shell-escape  -jobname "Test" "\expandafter\def\csname sa@
internal@run\endcsname{1}\input{Test}")...executed.
runsystem(convert.exe -density 300 Test.pdf  -quality 90 Test.png)...executed.
Class standalone Warning: Conversion unsuccessful!
(standalone)              There might be something wrong with your
(standalone)              conversation software or the file permissions!

I have updated ImageMagick to version 6.8.9.

I have found this question with a similar problem, but the solutions provided do not help me or the author. Hopefully someone can help me now.

Thanks in advance.

Best Answer

Find an exe file - magick.exe, then make two copies of it with name "covert.exe" "imgconvert.exe" in the same folder. Then run your command again.

You can find the file in the folder of ImageMagick, which is "C:\Program Files (x86)\ImageMagick-7.0.6-Q16" for me.

You get this error because the new version of ImageMagick changed the name of "covert.exe" to "magick.exe" while the standalone package didn't know that. For the file "imgcovert.exe", it maybe needed for windows user for some standalone text file to avoid another convert.exe in windows.