Is there a way to create default templates in any GUI?

This topic contains 0 replies, has 1 voice, and was last updated by  Forums Archives 5 years, 10 months ago.

  • Author
    Posts
  • #5069

    by willsteele at 2012-09-03 09:03:26

    I want to be able to open an instance of PowerShell ISE (or any other GUI) and have a template form appear. It would contain my standard formatting: prefilled help, regions, etc. Does anyone have hints on how to set up PowerShell ISE so I can accomplish this?

    by DonJ at 2012-09-03 09:17:08

    I imagine you'd have to do this as a WPF add-on tool. http://blog.codeassassin.com/2012/01/16 ... d-on-tool/ suggests that your tool receives new file notifications, meaning you could trigger on that. I imagine you could show (for example) a library of "templates."

    Then again, it might be easier to just do this as a snippet, using one of the existing Snippet add-ons. Yeah, you'd have to take the one extra step of adding the snippet to each new file you created... but that would likely be less effort, over time, than writing a whole add-on in Visual Studio.

    by willsteele at 2012-09-03 12:49:56

    Thanks for pointing that one out Don. I hadn't seen that post. Let me give it a whirl. If I get something useful I'll post back to this thread.

You must be logged in to reply to this topic.