ITcPlcLibraryManager::RemoveReference
Removes a reference from the actual PLC project. A reference can either be a library or a placeholder.
Please note: In case of a library, this only removes the reference, not the actual library file from the repository. For this, the method UninstallLibrary() needs to be used.
Similar to the method AddLibrary(), a library can be removed either by specifying its attributes (Name, Version, Company) or display text.
HRESULT RemoveReference(BSTR bstrLibName, BSTR bstrVersion, BSTR bstrCompany);
Parameters
bstrLibName |
[in] : Name of library |
bstrVersion |
[in, optional, defaultvalue("")] : |
bstrCompany |
[in, optional, defaultvalue("")] |
Comments
Two common ways to remove a PLC library are:
- libraryManager.RemoveReference("Tc2_MDP", "3.2.0.0", "Beckhoff Automation GmbH"); // Removing library via its attributes
- libraryManager.RemoveReference("Tc2_MDP, 3.2.0.0 (Beckhoff Automation GmbH)"); // Removing library via its display name
Where librayManager is an object of type ITcPlcLibraryManager.