Hello
I am not sure that I can help in this case, but I will still throw some ideas.

On Thu, Apr 8, 2010 at 7:28 PM, David Hewitt <dhewit...@gmail.com> wrote:
> This is a bit of a tangent from true LyX issues, but it is related and
> I suspect the expertise exists on this list to solve my problem. I
> appreciate any help. For those also on the R-Help mailing list, I
> apologize for the duplication.
>
> I use LyX on a Windows XP machine with R 2.10.1 and a recent
> installation of MiKTeX 2.8. I followed Jeff Laake's instructions on
> the LyX Wiki (which I recently posted! --
> http://wiki.lyx.org/LyX/LyxWithRThroughSweave) and had things all set
> up to run Sweave and Stangle and then make the PDF through R (though a
> batch script called from LyX then on to a MakeSweave.R file that does
> the work through R). All of this system worked just fine until I ran
> some MiKTeX updates yesterday.
>
> After the updates yesterday, which I noticed included the miktex core
> stuff, everything goes smoothly except that the code in the
> MakeSweave.R file that runs texi2dvi (an R function that calls the
> MiKTeX-distributed texi2dvi.exe to do the work) seems not to produce a
> PDF but gives no warnings or errors.
>
> The contents of the batch file are:
>
> Rterm --no-site-file --no-save -f "C:/Program Files/LyX
> 1.6.5/bin/MakeSweave.R" --args %1
>
> The batch file is called in the temporary directory where LyX does its work,
>
> The MakeSweave.R contents are:
>
> library(tools)
> args <- commandArgs()
> filename <- args[length(args)]
> Sweave(filename)
> Stangle(filename)
> basename <- sub("\\.(Rnw|Rtex|nw)$", "", filename)
> texi2dvi(paste(basename, ".tex", sep=""), pdf=TRUE)
>
> I run LyX from a command window and watch what goes on in the
> background. All goes fine through the whole process, texi2dvi runs and
> finishes (and I can confirm that it finds and executes texi2dvi.exe in
> the MiKTeX bin), and then LyX pukes an error that it cannot open the
> PDF because the PDF does not exist. Indeed, if I check the temp
> directory
> for LyX, all files are present but the PDF. I get no other warnings or
> errors from texi2dvi and cannot figure out why this happens.
>
Did you look at Document > LaTeX log? Sometimes it will display errors
that are not popped-up by LyX.


> Can someone help me figure out why texi2dvi fails to produce a PDF?
> Does anyone know if it is perhaps something about MiKTeX and the way
> the texi2dvi.exe works? Might it be possible to bypass that program
> and do the conversion via LyX more directly after R finishes the
> Sweaving and Stangling?
>
Did you try pdflatex, or ps2pdf?
Liviu


> A potential complication (as always) is that I am working in a
> non-Admin account on the machine. I can invoke Admin permissions to
> change things and had managed to get everything working before.
> Permissions may be an issue, but I have set full access to all the
> folders involved in this process (R, LyX, MiKTeX bins for example),
> and this got it working prior to updates. I am hoping that is not it.
> It seems like an issue with texi2dvi.
>
> Dave Hewitt
> Research Fishery Biologist
> USGS Western Fisheries Research Center
> Klamath Falls Field Station, Oregon
> http://profile.usgs.gov/dhewitt
>



-- 
Do you know how to read?
http://www.alienetworks.com/srtest.cfm
http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader
Do you know how to write?
http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail

Reply via email to