Search for "ie copy clipboard" and you will find lots of different solutions. Two examples for inspiration:
http://www.htmlgoodies.com/beyond/clipboard.htmlhttp://www.dynamicdrive.com/dynamicindex11/copytext.htm I believe people have had problem with running scripts inside CHM files since Microsoft changed the security model for Internet Explorer (which is used to render the HTML inside HH.exe). That started with the release of XP SP2, so you might need to watch out for that. You might want to check MSDN or Microsoft.com to see if there is any specific information about this.
Or perhaps you could use this to build your CHM as it mentions that it includes a built-in copy to clipboard function:
http://shfb.codeplex.com/