I'm personally pretty sick of asking people to enclose their code in tags, so I thought up a simple way to make sure that A user adds code tags to their code. I plan to write a simple program in VB.NET which will rely on the following principles:
1: Most users use browsers which display the page title of the selected webpage
2: Most users will not write code on the webpage, they will copy it into the textbox for the post body, from a development program.
What I plan to do is write a program which monitors window titles(say every 500ms), and if the title of the selected window text contains "Posting New Topic - Dream.In.Code", then the program will read the data on the clipboard, and if the data on the clipboard ends with/starts with certain keywords (such as "Private Sub" to start with, or "End Sub" to finish with), then the program will automatically add the text "[.code]" and "[./code]" (without the "."s) to the start and end of the text, assuming that the user is going to copy the text into the topic body textbox. When the user does copy the text into the text/body textbox, then it will already have the code tags inserted.
What do you guys think of my idea/do you have any ideas for improvements on it?
This post has been edited by Jack Eagles1: 09 January 2011 - 03:31 PM