0X000401E5

MK_S_HIM (0X000401E5): Why OLE Drag-and-Drop Fails

Windows Errors Intermediate 👁 9 views 📅 Jun 13, 2026

OLE drag-and-drop breaks when the moniker prefix—the registration key for your app's clipboard format—is missing or malformed. Here's the fix.

What's Actually Happening Here

The error 0X000401E5 with the symbolic name MK_S_HIM stands for Moniker Status: HIM — Common Prefix is Input Moniker. In plain English: OLE (Object Linking and Embedding) can't find the moniker prefix that should connect your drag-and-drop source to the clipboard format it registered. This isn't a random crash—it's a structural failure in how Windows handles data transfer between applications.

You'll see this most often when dragging content from a custom or older app into another OLE-aware app (think Outlook, Excel, or certain legacy line-of-business software). The source app tried to register a clipboard format but botched the moniker prefix part. Or the Registry got corrupted. Or you're mixing 32-bit and 64-bit OLE handlers—that's a classic tripwire.

Cause #1: Missing or Corrupted Input Moniker Prefix in the Registry

This is the most common cause. When an app calls RegisterClipboardFormat and then tries to build an OLE moniker for a drag-drop operation, Windows looks for a Registry key under HKEY_CLASSES_ROOT\CLSID\{your-clsid}\MonikerPrefix. If that key doesn't exist, or the value doesn't match what the app expects, you get 0X000401E5.

The fix is to verify and repair that Registry key. Here's the exact path:

HKEY_CLASSES_ROOT\CLSID\{your-apps-clsid}\MonikerPrefix

The default value should be a string like MyApp or MyApp.Document—whatever your app originally registered. You can check the app's documentation or decompile its setup to find the right prefix. If the key is missing, create a new REG_SZ value named MonikerPrefix and set it to the correct prefix string.

A real-world scenario: I've seen this happen after a Windows 10 22H2 feature update reset certain CLSID entries. The fix was to re-run the app's installer (which rewrites the Registry key) or manually restore it from a backup.

Why this works: The moniker prefix is essentially a namespace for the clipboard format. Without it, OLE can't resolve the moniker during drag-drop, so it returns MK_S_HIM to signal the prefix lookup failed.

Cause #2: 32-bit OLE Handler Registered on a 64-bit System (or Vice Versa)

If your app is 32-bit and you're on a 64-bit version of Windows, OLE's COM registration gets redirected. The app's CLSID might be in HKEY_CLASSES_ROOT\Wow6432Node\CLSID instead of the main HKEY_CLASSES_ROOT\CLSID. Drag-and-drop operations that cross the bitness boundary can fail with 0X000401E5 because the moniker prefix lives in the wrong hive.

Check both locations:

HKEY_CLASSES_ROOT\CLSID\{your-clsid}\MonikerPrefix
HKEY_CLASSES_ROOT\Wow6432Node\CLSID\{your-clsid}\MonikerPrefix

If the moniker prefix exists in the 32-bit node (Wow6432Node) but not in the 64-bit node, copy it over. Or better yet, use a reg file that writes to both. Example reg file content:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\CLSID\{your-clsid}\MonikerPrefix]
@="YourPrefix"

[HKEY_CLASSES_ROOT\Wow6432Node\CLSID\{your-clsid}\MonikerPrefix]
@="YourPrefix"

The real fix: Most developers don't realize that drag-and-drop in OLE is strict about bitness. A 32-bit source can't hand a moniker to a 64-bit sink without both registry hives having the same prefix. If you maintain the app, consider recompiling to match your target OS bitness, or register the moniker prefix in both nodes during setup.

Cause #3: The App's Clipboard Format Registration Is Incomplete

Sometimes the app registers the clipboard format using RegisterClipboardFormat but forgets to also register the OLE moniker prefix. This is a programming mistake, not a corruption. The 0X000401E5 appears only when the app actually tries to create a moniker—so you might see it intermittently if the app has code paths that skip registration under certain conditions.

To fix this from the app side (if you have access to the source code or can patch it):

  1. Ensure RegisterClipboardFormat is called early in the drag-initiation code (before DoDragDrop).
  2. Immediately after that, create the moniker prefix by calling CreateItemMoniker with the correct prefix string.
  3. Register that prefix in the system Registry under HKEY_CLASSES_ROOT\CLSID\{your-clsid}\MonikerPrefix — ideally during installation, not at runtime.

If you can't modify the app, use a shim or compatibility layer. I've had success with Application Verifier's HighVersionLie + RegistryKey layer to inject the missing moniker prefix at runtime. It's hacky but works when the app is abandoned.

One more thing: Don't confuse 0X000401E5 with 0X800401E5 (MK_E_SYNTAX). That one is a syntax error in the moniker string. 0X000401E5 is a success code (note the 0004 prefix) — it's telling you the moniker was created, but with a common prefix that's also an input moniker. The issue is that the app doesn't handle this partially-successful state gracefully.

Quick-Reference Summary Table

Cause Fix Difficulty
Missing/corrupt MonikerPrefix Registry key Restore or create the REG_SZ string under the CLSID Intermediate
32-bit vs 64-bit OLE handler mismatch Copy moniker prefix to both CLSID and Wow6432Node\CLSID Intermediate
Incomplete clipboard format registration in app code Add RegisterClipboardFormat and CreateItemMoniker before drag-init, or use a shim Advanced

Run through these in order. Nine times out of ten, the Registry key is the culprit. If you're still hitting 0X000401E5 after all three, check the app's event log for OLE registration failures — there might be a deeper COM initialization issue.

Was this solution helpful?