2

I used previous comments and tried to insert an image in a very easy way, but I don''t know why it gives me errors and doesn't produce results. I have my picture in the same folder of .tex, but doesn't work. here is the simplest code I use:

\documentclass{article}

\usepackage{graphicx}

\begin{document}

\includegraphics{picture}

\end{document}

==========================

and here is the error: enter image description here

  • 2
    Hi, welcome. Looks from the error as though the image you're trying to include is corrupt. Note it says "no JPEG header found". Have you tried other images? – Torbjørn T. Apr 11 '18 at 17:50
  • Off topic: Observe that blank lines in LaTeX have meaning(new paragraph), so do not make any, where they do not belong. – hpekristiansen Apr 11 '18 at 18:07
  • Hi, thank you. I am happy I am here having you guys helping. You might be right, cause the format of my picture is .tiff and I had changed that to JPEG. So does LaTeX knows .tiff? – Benjamin Soraghi Apr 11 '18 at 18:13
  • I created a .PNG file (using Matlab) Torbjørn T, but it still gives me the same error. – Benjamin Soraghi Apr 11 '18 at 18:29
  • 1
    unrelated but \center is not intended to be used as a command like that, use \centering – David Carlisle Apr 11 '18 at 18:34

Your Answer

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

Browse other questions tagged or ask your own question.