Good Afternoon To All AUGI Members:
I am having a problem that is confusing me at the moment....!
I have a Autolisp routine that takes the current working drawing, performs a saveas to a new drawing name, inserts an 8 1/2"x11" sketch format and then creates a floating viewport to a user specified scale. When the routine is finished the user will activate the viewport and pan the sketch to a desired location. The user will then save and close the drawing file.
The next time that drawing is opened the viewport on the sketch drawing reverts back to the original location when the floating viewport was first created and does not save the viewport location that the sketch was panned to before saving the file.
Below is a portion of the code that creates the new viewport in this routine...:
(Command "-LAYER" "U" "DEFPOINTS" "")
(Command "-LAYER" "T" "DEFPOINTS" "")
(Command "-LAYER" "ON" "DEFPOINTS" "")
(Command "-LAYER" "M" "Defpoints" "")
(Command "-VPORTS" "0.75,0.375" "8.125,9.3125")
(Command "-VPORTS" "ON" "L" "")
(Command "MSpace")
(Command "zoom" "1/48xp")
(Command "PSpace")
(Command "Zoom" "E")
(Command "Qsave")
Can anyone think of a reason why the panned location of the viewport is not being saved the first time the drawing is saved....??
Once the drawing is opened a second time and the viewport is panned to the desired location again and the drawing is saved.......the next time the drawing is opened everything is OK. The problem only exists the first time the viewport is created, panned and saved.
Any assistance with this matter would be appreciated.
Regards,
Vince