"How do I include source listings in a doc" has to be the number one question asked on the IRC channel. We really don't have a good solution yet, but we do have a rather old patch done by Herbert :
http://bugzilla.lyx.org/show_bug.cgi?id=508 It needs updating and debugging ... regards john -- Khendon's Law: If the same point is made twice by the same person, the thread is over.