RemoveControlByName Function OCCACHE.DLL

Announcements and discussion for PInvoke

RemoveControlByName Function OCCACHE.DLL

Postby all3nmfa » Fri Sep 28, 2007 4:06 pm

I'm in need of some help using this win api dll. can someone please convert to c#. TIA
http://msdn2.microsoft.com/en-us/library/Aa768173.aspx


allen
all3nmfa
 
Posts: 2
Joined: Fri Sep 28, 2007 4:03 pm

Postby all3nmfa » Fri Sep 28, 2007 9:33 pm

i think i have the code converted but something is wrong. am i passing the wrong information? its only deleting the associated INF file but doesn't delete the dll's. it also still leaves all the registry information. anyone have any insight to my problem?


[DllImport("occache", EntryPoint = "RemoveControlByName")]
static extern int RemoveControlByName(string lpszFile, string lpszCLSID, string lpszTypelibid, bool bForceRemove, int dwISDistUnit);



private void button1_Click(object sender, EventArgs e)

{
int retval= 0;

retval = RemoveControlByName(@"C:\\WINDOWS\\Downloaded Program Files\\MFA.dll", "{53A8AEF8-5503-4B78-A091-634BB68DEECE}", "ActiveX Control", true, 0);
all3nmfa
 
Posts: 2
Joined: Fri Sep 28, 2007 4:03 pm


Return to PInvoke.Net

Who is online

Users browsing this forum: No registered users and 0 guests