On Nov 01, 2014, at 17:57, jgill <joegillespie2...@gmail.com> wrote:
> So, it is a previously saved file but is being modified and saved to a 
> different location. It will not be replacing the original template.

______________________________________________________________________

Hey Joe,

Okay.  Something like this should work.

-------------------------------------------------------------------------------------------
set _template to alias ((path to home folder as text) & 
"test_directory:BBEdit_Test_Dir:Template.txt")
set basePath to ((path to documents folder as text) & "(2014):")
tell (current date)
  set _month to its month as text
  set _year to its year
end tell
set newFileName to _month & " " & _year & ".html"
set newFilePath to basePath & newFileName

tell application "BBEdit"
  set newDoc to open _template
  tell newDoc to save to newFilePath
  tell document newFileName
    # Do your edits.
    # Save.
  end tell
end tell
-------------------------------------------------------------------------------------------

Are you actually pasting into the newly opened template?  If so there's 
probably a better way.

--
Best Regards,
Chris

-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or would like to report a problem, please email
"supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>

--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To post to this group, send email to bbedit@googlegroups.com.

Reply via email to