I know this error is infuriating. You're in the middle of debugging an app or configuring a message queue, and bam — 0X00000487 (ERROR_MESSAGE_SYNC_ONLY). The message reads: "The message can be used only with synchronous operations." Your program just told you it can't use async here. So what went wrong?
This error usually means something tried to send or receive a message asynchronously on a queue that only supports synchronous operations. Think of it like trying to use a walkie-talkie that only works push-to-talk, but your app is waiting for a reply. It's a mismatch between how the queue is set up and what your code expects.
Cause 1: App or DLL Calling Async on a Sync-Only Queue
This is the most common culprit. Some application, often an old one or a custom-built tool, calls MQReceiveMessage or MQSendMessage with the MQ_ACTION_RECEIVE flag set for asynchronous behavior. But the queue itself was created with synchronous mode only. MSMQ (Microsoft Message Queuing) can be picky about this.
Real-world trigger: I've seen this happen with legacy ERP systems that send batch updates. They pop up in Windows Event Viewer as error 0X00000487 right after a server reboot or after installing a Windows Update that tightened MSMQ permissions.
Fix for app config:
- Open your application's configuration file (usually
app.configorweb.config). - Look for a section related to MSMQ or message queue settings. Search for
syncModeorasynchronous. - Change the setting to
syncOnlyor remove any async flag. For example, in some apps:
<appSettings>
<add key="MessageQueueSyncMode" value="Sync" />
</appSettings>
If you can't find a config file, check the source code or contact the vendor. Quick test: try running the app with a simple synchronous call (e.g., MessageQueue.Receive() instead of BeginReceive() in C#). If the error disappears, you've confirmed the issue.
Cause 2: MSMQ Queue Properties Set to Sync-Only
Sometimes the queue itself is locked down. MSMQ lets you set a queue's transactional or sync properties during creation. If someone (or a script) created the queue with MQ_QUEUE_TYPE_SYNC_ONLY, any async try will fail with this error.
Check queue properties:
- Open Computer Management → Services and Applications → Message Queuing.
- Right-click the problematic queue and select Properties.
- Go to the General tab. Look for a checkbox that says Make this queue available for asynchronous operations. If it's unchecked, that's your problem.
- Check it and click OK.
If you don't see that option, the queue might be a transactional queue. Transactional queues in MSMQ are sync-only by design — they require a transaction context for every operation. You can't slap async on them without changing the queue type. For transactional queues, your only option is to delete and recreate the queue without the transactional flag, but be careful: that might break other apps relying on transactions.
PowerShell alternative: If you're on Windows Server and manage queues remotely, use this:
Get-MsmqQueue -Name "YourQueueName" | Set-MsmqQueue -Transactional $false
But again, only do this if you're sure transactional behavior isn't needed. I've seen admins break production apps by flipping this blindly.
Cause 3: Registry Key Misconfigurations in MSMQ
This one's rarer but nasty. Some MSMQ settings live in the registry, especially on older Windows versions like Windows 7 or Server 2008 R2. A corrupted or manually edited registry key can force all queues to sync-only mode.
The key to check:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSMQ\Parameters
Look for a DWORD value named AllowAsynchronous. If it's set to 0, that disables async across the board. Set it to 1 to enable async globally. If the value doesn't exist, MSMQ defaults to allowing async — but a misconfigured script or group policy might have added it.
Fix steps:
- Open Regedit as Administrator.
- Navigate to the above path.
- If
AllowAsynchronousexists and is0, double-click it and change to1. - If it doesn't exist, you can safely leave it. But if you suspect group policy, run
gpupdate /forceand check Event Viewer for policy conflicts. - Restart the MSMQ service:
net stop MSMQ && net start MSMQ.
After the restart, test your app. This fix has saved me twice on Windows Server 2012 R2 where a past admin had locked it down for security. It worked — but only because the queue didn't really need sync-only.
Quick-Reference Summary Table
| Cause | Where to Look | Fix |
|---|---|---|
| App calling async on sync-only queue | App config file or source code | Set sync mode, remove async flag, use Receive() not BeginReceive() |
| MSMQ queue set to sync-only | Computer Management → Message Queuing → Queue Properties | Enable async checkbox, or recreate queue without transactional flag |
| Registry disables async globally | HKLM\SOFTWARE\Microsoft\MSMQ\Parameters |
Set AllowAsynchronous DWORD to 1, restart MSMQ service |
If none of these work, you might be dealing with a corrupt MSMQ installation. Reinstall MSMQ via Windows Features, then recreate the queues from scratch. This happened to me once after a botched Windows update — nothing else fixed it.
Hope this helps you get back to work. You've got this.