I was going crazy with the LyX and MikTeX configuration for a new class,I think I have done it matching the step! but None I get
here what i've done:
Get a copy of the class file, and copy
it into a folder with the same name
into
C:\Users\AppData\Roaming\MiKTeX\2.8\tex\latex.
So, forociamthesis.cls
, you should
have a folder calledociamthesis
within
C:\Users\\AppData\Roaming\MiKTeX\2.8\tex\latex
.
This is Windows Vista / Windows 7
specific, you will soon see why…
Create a new file and paste the
following into it:
% Do not delete the line below; configure depends on this
\DeclareLaTeXClass[xxx]{article (xxx)}
Input general definitions
Input
stdclass.inc
replacing xxx
with the class name (without the .cls
extension).
In my case, xxx is eethesis
, and the code above becomes:
% Do not delete the line below; configure depends on this
\DeclareLaTeXClass[ociamthesis]{report (ociamthesis)}
Input general definitions
Input stdclass.inc
Thanks goes out to Adding a new class in LyX for this.
Save this file to
C:\Program
, naming
Files\LyX16\Resources\layouts
itociamthesis.layout
. In a command
prompt (type cmd in start menu), type
texhash. What you will now see it
doing is iterating through several
folders for new classes, one of which
(C:\Users\AppData\Roaming\MiKTeX\2.8\
)
is where we copied the ociamthesis.cls
class file into.
Within Lyx, hit Tools > Reconfigure, then restart Lyx.
but when I try to run, I get this error message : LaTeX Error :
File 'ociamthesis.sty' not found
Can anyone help me?
Best Answer
I don't use Lyx (and looking at your complicated description I'm quite grateful ;-)) but two remarks:
.cls
file while your error message miss a.sty
. If you quoted the error message correctly, your lyx configuration is probably wrong.cls
is not found then either your root (C:\User\...\2.8
) is either not a known root of miktex or you didn't update its FNDB. Check in miktex settings if the root is listed (check "show miktex roots) and update the FNDB. If you have a multiuser setup do it in user and admin mode.