Hi, Please refer to my previous message for the problem. "Bug in subdocument bibtex support 1.3.6, 1.3.7-pre2" What I could see from looking at the code is the following.
The copy problem is around line 244 in insetbib.C database = mangled_filename(database); string const out_file = MakeAbsPath(database + ".bib", buffer->tmppath); I assume buffer->tmppath is set to the sub documents temp path. (same as for the images) Maybe the buffer->tmppath should be the path to where the temp documents .tex file is output to. (thus the main documents temp path) I have no knowledge of the main document / sub document mechanisms. So another solution might be constructing a relative path. The temp dir contains no spaces, so this should be safe. And even if there is no main document, stepping one path back and into the correct one again will pose no problem. Maybe just add some checking to see if there is no absolute path already. Inserting something like this where the actual tex is output might work. (about line 277, see the -- below) // Chomp off everything in the temp path except the last directory. String last_path_bit = buffer->tmppath; while (int tmp_int=AnisPos("\", last_path_bit)>0) { last_path_bit=AnsiDelete(last_path_bit, 1, tmp_int); } // add the relative path. -- os << "\\bibliography{" << dbs_str << "}\n"; ++ os << "\\bibliography{../" << last_path_bit << "/" << dbs_str << "}\n"; This is from the lyx 1.3.7cvs downloaded from ftp.sylvan.com. Please excuse the use of AnisString / AnsiPos. I've only written one C++ program in Borland C Builder in windows and have no other knowledge of function / libraries. This is done from a more dominant windows/Delphi and avr-gcc c viewpoint. Hope it helps locating the problem. Regards, Johann