Click here to Skip to main content
11,490,642 members (71,336 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: C# VB Excel macros
Hi all,

I have an excel file with many different, but very similar, userforms
When i click on a cell in my worksheet a specific userform will open according to the cell text.

I wanted to know if there is a way to add a c# form to excel which will behave as a userform?
Since the visual studio interface is much simpler and a lot more generic then vb...

Posted 4-Mar-13 22:31pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

You have some possibilities:
1) Actually Excel (and practically all Office application) support Add-ins. Thus you could make a legacy excel add-in. There are several tutorials out there, but this is not the simplest one.
2) An other interesting approach:[^]
3) You can call managed code from excel vba, but it is not the wisest one, since vba runs in a rather undeterministic way. Start here:[^]
4) Interop Forms Toolkit[^] might be also an alternative to consider.
nirnirle at 7-Mar-13 4:20am
Thanks for your answer.
All of your suggestion seems reasonable, I will have to examine them more thoroughly.
Zoltán Zörgő at 7-Mar-13 4:51am
You are welcome.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 460
1 Andy Lanng 258
2 Sascha Lefèvre 240
3 OriginalGriff 188
4 Maciej Los 160
0 Sergey Alexandrovich Kryukov 9,713
1 OriginalGriff 8,475
2 Sascha Lefèvre 3,544
3 Maciej Los 3,106
4 Richard Deeming 2,370

Advertise | Privacy | Mobile
Web04 | 2.8.150520.1 | Last Updated 5 Mar 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100