\usepackage{fancyhdr}
\fancyhf{}
\fancyhead[RO,LE]{\textbf{\thepage}}
\fancyhead[LO]{\nouppercase{\textbf{\leftmark}}}
\fancyhead[RE]{\nouppercase{\textbf{\rightmark}}}
\pagestyle{fancy}
\include {1.Introduction}
\include {2.Background}
\include {3.Literature}
\include {4.Methodology}
\include{5.ExperimentalAnalysis}
\include{6.CaseStudy}
\include{7.Conclusion}
\include{Appendix}
答案1
你可以把效果放在\pagestyle
一个组中:
\documentclass[]{article}
\usepackage{blindtext}
\usepackage{fancyhdr}
\fancyhf{}
\fancyhead[RO,LE]{\textbf{\thepage}}
\fancyhead[LO]{\nouppercase{\textbf{\leftmark}}}
\fancyhead[RE]{\nouppercase{\textbf{\rightmark}}}
\begin{document}
\bgroup
\pagestyle{fancy}
\Blinddocument
\clearpage
\egroup
\blindtext
\end{document}