I'm not typically an Autocad programmer, so bear with me.
Background: I'm building a batch drawing processor (c# on ADT2006) with a plugin architecture. It will be very similar to Photoshop's Actions. Currently, the system will not load drawings into the editor to work on them; only opened through DBX. I think I may cause it to switch into interactive mode if any of the actions specified require the editor interface, but I'm not to that point yet.
Anyway, one of the actions is a simple WBlock operation. Since we don't open this in the editor, the operation is pretty fast. My problem is that if the drawing's UCS is set to something other than WCS and the plan view is set to this UCS, the resulting database ends up with its WCS set to the previous UCS. Without the editor, what is the best way to set everything to correct view before wblocking? Now that I think about it, I'm not even sure how to do this with the editor without sendcommand type of operation. Any ideas appreciated.