Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm trying to compile a simple ISO-8859-2 document,

\documentclass[twocolumn]{article}

\usepackage[czech]{babel}
\usepackage[latin2]{inputenc}
\usepackage[T1]{fontenc}

\usepackage[paperwidth=18cm, paperheight=13cm]{geometry}

\begin{document}
České vysoké učení technické v Praze
\end{document}

The compilation fails at the "č" letters. It keeps saying

! Package inputenc Error: Keyboard character used is undefined
(inputenc) in inputencoding `latin2'.

despite the fact that "č" is a latin2 character.

share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

There seems to be a conflict between the encoding used in your document and the one of your editor. Both encodings: the one declared in your document using inputenc and the one used for your editor need to be the same; otherwise errors will appear. Make sure both coincide and the problem will disappear.

share|improve this answer
    
Thanks for your answer, but the use of latin2 is mandatory in my project. –  Grant May 24 '13 at 1:02
    
@Grant may I ask why is this so? –  Gonzalo Medina May 24 '13 at 1:03
    
I'll be processing csv files that are in ISO-8859-2. –  Grant May 24 '13 at 1:04
1  
@Grant I see. Is your editor configured to also use ISO-8859-2? –  Gonzalo Medina May 24 '13 at 1:05
    
I set it to ISO-8859-2, rewrote the sample and it started working. Thank you. –  Grant May 24 '13 at 1:10
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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