Does anyone here have experience with/in developing IE extensions that can share their knowledge? This would include code samples, or links to good ones, or documentation on
Another cool approach would be to check out:
http://www.crossrider.org
It's a framework based on JS with jquery which lets you develop browsers extensions for IE, FF and Chrome using a single common JS code. Basically the framework does all the nasty work and you're left with writing your applications code.
Developing C# BHOs is a pain-in-the-arse. It involves a lot of icky COM code and p/invoke calls.
I have a mostly finished C# BHO here, which you are free to use the source for whatever you want. I say "mostly", because I never did figure out how to save appdata under IE Protected Mode.
I agree with Robert Harvey, C# 4.0 features improved COM interop. Here's a bit of older C# code, in desperate need of a re-write.
http://www.codeproject.com/KB/cs/Attach_BHO_with_C_.aspx
This is an attempt to simplify things by avoiding ATL and going with Spartan COM:
C++ and COM to get BHOs going
In the Build Events tab, set Post-build events command line to: (x64) is listed below
"C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\NETFX 4.0 Tools\x64\gacutil.exe" /if "$(TargetDir)$(TargetFileName)"
"C:\Windows\Microsoft.NET\Framework64\v4.0.30319\RegAsm.exe" /u "$(TargetDir)$(TargetFileName)"
"C:\Windows\Microsoft.NET\Framework64\v4.0.30319\RegAsm.exe" "$(TargetDir)$(TargetFileName)"
I want the Build Events tab , set Post-build events command line to (32 bit operating system)
"C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\gacutil.exe" /if "$(TargetDir)$(TargetFileName)"
"C:\Windows\Microsoft.NET\Framework\v4.0.30319\RegAsm.exe" /u "$(TargetDir)$(TargetFileName)"
"C:\Windows\Microsoft.NET\Framework\v4.0.30319\RegAsm.exe" "$(TargetDir)$(TargetFileName)"
If you are not trying to reinvent the wheel, you might try Add In Express for IE . I have used the product for the VSTO stuff, and its pretty good. Also they have a helpful forum and quick support.