2

im having a hard time with TeXnicCenter 2.0 (with MikTex) on Windows 7. I set up a quite simple code. But the letters äüö seem to appear when they want to. I got a project file with another file bounded with \input. In both files I wrote some ö or ä to chek which package can deal with it. But apparently nither one can. Here is my code:

\documentclass[a4paper,11pt]{report}

\usepackage[ngerman]{babel}

\usepackage[T1]{fontenc}

%\usepackage[latin1]{inputenc} 

%\usepackage[utf8]{inputenc}   

%\usepackage[ansinew]{inputenc}

\begin{document}

\input{LaTeX1}

test ö


\end{document}

in the file LaTeX1.tex I just wrote text ä

So if i use:

\usepackage[latin1]{inputenc}  -> no errors, but "test ö" is not shown
\usepackage[utf8]{inputenc}   ->  one error. no "ä" is not shown. "test ö" is shown correctly
\usepackage[ansinew]{inputenc} -> no errors. "text ä" is shown, "test ö": shown with stange signs

Im a LaTex beginner so please dont answer to complicated :)

Thanks for your answers!

Vicky

  • It's important to know what encoding you've actually saved the two files in: they might not be the same as each other! – Joseph Wright Jun 4 '14 at 15:18
  • 1
    Change the encoding of LaTeX1.tex to utf8. Then use \usepackage[utf8]{inputenc}. You could also use {\inputencoding{ansinew}\input{LaTeX1}} to change the settings locally. But mixing encodings in one project can get confusing so I wouldn't recommend it. – Ulrike Fischer Jun 4 '14 at 15:23
  • What happens if you replace \input{LaTeX1} with text ä? Then you'd just be reducing the problem down to a single file, rather than two. – John Wickerson Jun 4 '14 at 15:23
  • 1
    Ok! Now, how can I change the encoding of LaTeX1.tex to utf8? And how can I see which encoding is used in the file? – Vicky Jun 4 '14 at 15:28
  • to John Wickerson: if the code works I wont to start a big project with several files included with \input. So the text ä stands for a hole document with a lot of text and many ä ü ö's :) but good idea anyway – Vicky Jun 4 '14 at 15:36

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.