views:

47

answers:

3

Hi,

Does anyone know how to invoke/display the Windows Certificate Export Wizard Programmically within C#.NET whilst providing an X509 Certificate?

Many thanks

A: 

I think you'll have to P/Invoke CryptUIWizExport from the Cryptui.dll.

GregS
Thats GregS, Do you have any ideas how to implement this?The only information I can find on CryptUIWizExport so far is this on the MSDN site:http://msdn.microsoft.com/en-us/library/aa380395.aspxMy attempts to DLLImpport a wrapper for it so far have failed. Do you have any ideas on how to do it?Many thanks
MdbUK
A: 

I don't know, but i do vote for program this wizard in C#. Look at X509Certificate2UI class and X509Certificate2.Export method. You will find there everything you need to export cert from store.

sinm
Hi Sinm, it does not look like it is possbile to invoke the Microsoft Certificate Export Wizard from those classes. :(
MdbUK
A: 

The Solution to my question has been answered here:

http://stackoverflow.com/questions/3224117/how-to-p-invoke-cryptuiwizexport-function-in-c-net

MdbUK