libiconv-2.dll Error in Windows 10 and 11: Text encoding conversion errors

An editor can read ordinary ASCII but fails when converting a legacy text file or reports libiconv-2.dll missing.
What this DLL does
GNU Libiconv can provide character encoding conversion to software using the Windows package.
Start with this check
Use an approved test file whose source encoding is known. Record the conversion target and the module path if named.
Record the exact error, when it occurred, and the full module path if available. For a crash, open View reliability history from Start and look for the matching entry. The affected app, faulting module and exception code help distinguish an app problem from a system-wide one.
Choose the repair that fits
Repair the publisher’s app package or restore the matching Libiconv dependency. Keep the original file and convert a copy.
Start with Microsoft’s app repair options if only one supported application fails. If unrelated built-in Windows features also fail and you suspect system file corruption, use Microsoft’s DISM and System File Checker instructions. Use supported packages and avoid downloading individual DLL files.
Verify the repair
Open the converted test file and verify that representative non-ASCII characters survived.
For a related check, see libexpat-1.dll troubleshooting. Browse the DLL Errors & Fixes Library. Official reference: MSYS2 Windows package manifest for libiconv.