Author Topic: hotkey text added to file  (Read 8453 times)

williethewimp

  • Junior Community Member
  • Posts: 6
  • Hero Points: 0
hotkey text added to file
« on: February 07, 2017, 06:19:17 PM »
Hi,

Does Slickedit support the ability to create headers/blocks of generic code and then insert it in your code when you type a hotkey or some type of trigger? I don't know what it is called, so I don't know what to look for in the menus.

Thanks!
Todd

williethewimp

  • Junior Community Member
  • Posts: 6
  • Hero Points: 0
Re: hotkey text added to file
« Reply #1 on: February 07, 2017, 06:23:36 PM »
Nevermind, I guess it is just "record a macro, paste the text that you want, stop the macro and bind it".

Thanks,
Todd

LBCEi

  • Senior Community Member
  • Posts: 261
  • Hero Points: 21
Re: hotkey text added to file
« Reply #2 on: February 07, 2017, 09:09:46 PM »
That is one way to do it.  You can also use the 'aliases' features.  Search the Help.  This feature is quite flexible and you can even set it up to prompt for input when expanding an alias to customize the text that gets inserted.

I use this to insert comment headers when creating a new source file, for example.

williethewimp

  • Junior Community Member
  • Posts: 6
  • Hero Points: 0
Re: hotkey text added to file
« Reply #3 on: February 08, 2017, 05:46:09 PM »
I'll take a look, thanks! It would be nice to add some specific names to the code generation.

Todd

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 6823
  • Hero Points: 526
Re: hotkey text added to file
« Reply #4 on: February 10, 2017, 02:18:57 AM »
You can have an alias prompt for parameters so you can insert them in your alias text. SlickEdit also support code templates which is used to generate one or more files (not pieces of files like aliases).