Hi,
Have a look at the MSDN article:
Exercising the Firewall using C++[
^]
The VB script sample you posted appears to be removing a firewall application rule. If you wanted to do this under COM with C++ you would need modify the line in the sample function
WindowsFirewallAddApp:
hr = fwApps->Add(fwApp);
And change it to:
hr = fwApps->Remove(fwApp);
Don't forget to rename the function to something like WindowsFirewall
RemoveApp or it will drive a future project maintainer crazy. :)
Best Wishes,
-David Delaune