OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: Kerry on July 31, 2008, 05:49:01 PM

Title: (dcl_project_saveas
Post by: Kerry on July 31, 2008, 05:49:01 PM

Does anyone have a small sample using (dcl_project_saveas ....

I'm getting an error:No object Instance
when I try to use it , so I'm obviously doing something wrong.

I'm trying to save ALL the current settings in a fairly complex project so they can be restored at the next invocation without the need for complicated writing and translation to and from a memory construct or data file

Regards
Kerry
Title: Re: (dcl_project_saveas
Post by: Kerry on July 31, 2008, 08:14:37 PM
This seems to work ..

(kdub:SaveTheProjectFile)

(defun kdub:SaveTheProjectFile (/ FNAME PROJECT)
  (if (setq fname (findfile "C:\\KDUB_TestSave.Modified.odcl"))
    (setq project (dcl_project_load fname))
    ;; else
    (setq project (dcl_project_load "C:\\KDUB_TestSave.odcl"))
  )
  (dcl_form_show kdub_pipeflanges_main)
  ;;
  ;; do mojo
  ;; then close
  ;;
  (dcl_project_saveas project "C:\\KDUB_TestSave.Modified.odcl" nil)
  (princ)
)



Though the Option List Values don't seem to be saved ?? Can anyone check this please ?

Regards
Kerry
Title: Re: (dcl_project_saveas
Post by: owenwengerd on August 01, 2008, 08:46:24 AM
Quote from: Kerry Brown on July 31, 2008, 08:14:37 PM
Though the Option List Values don't seem to be saved ??

Hmm, they should be.  What you're doing is exactly the same thing that happens when you open the file in the editor, modify it, then save it.
Title: Re: (dcl_project_saveas
Post by: Kerry on August 03, 2008, 09:33:21 PM

Owen , Do you want this reported as a bug ?
Title: Re: (dcl_project_saveas
Post by: owenwengerd on August 03, 2008, 10:42:43 PM
Yes, along with a small sample.
Title: Re: (dcl_project_saveas
Post by: Kerry on August 03, 2008, 11:14:40 PM
Done ..
Title: Re: (dcl_project_saveas
Post by: Kerry on August 05, 2008, 03:14:24 AM

For anyone wanting to follow up on this ..
This issue is being resolved.
https://sourceforge.net/tracker/index.php?func=detail&aid=2037360&group_id=187950&atid=923363

Thanks Owen

Regards
Kerry