I have rewritten the open command and would like Autocad 2015 to use my command. If, however I don't start in a dwg my code will not load(I undefined and redefined "open" in acad.lsp). Once a dwg is opened then my code is active. How can I force my open command to be the only one used?
add your code to the ACAD2014doc.lsp file as part of a s::startup function. This one loads with every drawing (instead of just once on opening AutoCAD) and works nicely for similar things on our end.
You should create / use "acaddcoc.lsp" to apply to every document.
acaddoc.lsp does not exist in an OOTB install (it will never be overwritten by a re-install).
Check help (search "acaddoc")
<Help Quote>Warning Do not modify the reserved acad<release>doc.lsp file. Autodesk provides the acad<release>doc.lsp file, which contains required, release-specific, AutoLISP-defined functions. This file is loaded into memory immediately before the acaddoc.lsp file is loaded. <release> represents the release of the AutoCAD-based product; for example, acad2012doc.lsp would be the file loaded by AutoCAD 2012-based products.</Help Quote>