# NGerman babel does not work

I need a bit of help with LateX as I am not the best. So the problem which I currently have is that the babel package [ngerman] does not work. The English works but I need the German one to work and I just cannot figure out why.

Sorry for coming back so late - The code is not the nicest ... sorry about that but I am no programmer

\documentclass[
12pt,
chapterprefix,
egregdoesnotlikesansseriftitles% no sans serif headings etc.
]{scrreprt} % for bigger size of text
%\providecommand*\Ifstr{\ifstr}% needed up to and including KOMA-Script version 3.27, see https://komascript.de/faq_deprecatedif
%\usepackage{blindtext}% only for dummy text
\usepackage{newtxtext}% <- changed
\usepackage[ngerman]{babel} %help: usepackage[ngerman]{babel} does not work ... \enquote: commas should be at the bottom in the beginning, not the top - not running - error line
\usepackage[final]{pdfpages}
\usepackage{csquotes} %enquote
\usepackage{graphicx}
\usepackage{MnSymbol,wasysym} %smiley
\usepackage{tabularx} % table x for certain width

\usepackage{setspace}

\usepackage{float}

\usepackage{tablefootnote}
\interfootnotelinepenalty=10000 %footnote won't run on two pages
\usepackage{footmisc} %footnotes indent
\setlength{\footnotemargin}{\parindent}  %footnotes indent

\newenvironment{hanging}[1][2em]{%  %Literaturverzeichnis
\ignorespaces
}{%
}

\setcounter{secnumdepth}{\chapternumdepth}% only parts and chapters should be numbered

%chapter in toc and on page (numbering)
\RedeclareSectionCommand[
font=\bfseries\large,% does the same as \setkomafont{chapter}{\bfseries\large}
tocentrynumberformat={\def\autodot{:}},
tocdynnumwidth
]{chapter}

\renewcommand*{\chaptermarkformat}{\chapappifchapterprefix{\nobreakspace}\thechapter\autodot:\enskip}

\IfArgIsEmpty{#1}
}

% section
\RedeclareSectionCommand[font=\sffamily\Large]{section}% does the same as \setkomafont{section}{\sffamily\Large}
% subsection
\RedeclareSectionCommand[
%indent=1em,% <- add this if the subsections should be indented
font=\itshape% changes the font, does the same as \setkomafont{subsection}{\itshape}
]{subsection}

% format headings with style=section, eg. section, subsection and subsubsection
\let\originalsectionlinesformat\sectionlinesformat
\renewcommand\sectionlinesformat[4]{%
\Ifstr{#1}{section}
{\originalsectionlinesformat{#1}{#2}{#3}{#4}}% original definition for other section levels
}

% use page style empty in in ToC, LoF and LoT
\AfterStartingTOC{\clearpage}

% rename LoF and LoT
\renewcaptionname{english}{\listfigurename}{Figures}
\renewcaptionname{english}{\listtablename}{Tables}

\begin{document}

• it is ngerman not nGerman. Jan 24 at 13:34
• Welcome to TeX.SE.
– Mico
Jan 24 at 13:35
• Hi, just tried the ngerman and it is still not running ... ! Package scrbase Error: \listfigurename' not defined at language english'. See the scrbase package documentation for explanation. Type H <return> for immediate help. ... l.86 \begin{document} ? Jan 24 at 13:39
• Between what you post and the \begin{document} on line 86 there are 50 lines of code where things could be going wrong. Please post a minimal code reproducing the issue, and post it as text, not as snapshot. Jan 24 at 13:57
• I reposted. I haven't been able to figure out the mistake in the past few days Jan 28 at 9:42

The problem is the combination

\usepackage[ngerman]{babel}
[...]
\renewcaptionname{english}{\listfigurename}{Figures}
\renewcaptionname{english}{\listtablename}{Tables}


You are loading babel with the ngerman option, meaning that the language english isn't defined. When you do

\renewcaptionname{english}{...}{...}


then you'll get the error.

If you are writing simply a German text then remove the two \renewcaptionname instructions.

• thank you so much! It makes total sense, it works! Jan 28 at 10:05