[Tex/LaTex] How to add something to the preamble in LyX

lyxpreamble

I'm trying to add something to the preamble, but don't know how. I tried Insert -> Latex Code and just picked places on my article, but I guess they were never in the preamble? I guess I cannot just put code into my article.

I can view source under View -> Source. Can I edit source? It is not under Edit.

Best Answer

LyX hides LaTeX Preamble under the menu option Document > Settings... > LaTeX Preamble.

enter image description here