| Previous | Next |
| VFW_S_NO_MORE_ITEMS | VIEW_S_ALREADY_FROZEN |
DATA_S_SAMEFORMATETC
Equivalent FORMATETC already represents the data
DATA_S_SAMEFORMATETC is HRESULT 262448 (0x00040130) from winerror.h. The documented description is “Data has same FORMATETC.” The high-order severity bit is clear, so this is a success result, but it carries more information than plain S_OK.
The OLE data operation succeeded and determined that the relevant FORMATETC is equivalent to the one already in use.
State to verify
The central question is whether format, target device, aspect, index, and supported storage-medium flags are equivalent for the operation that performed the comparison.
A reliable interpretation of this result names the exact method contract, the object instance, and the outputs that remain valid. This prevents a success-with-information result from being promoted to full success or demoted to a generic error.
Where the result is encountered
- This result can appear in IDataObject format negotiation; record the producing interface and method.
- It can appear in data advisory registration and cache management; record the producing interface and method.
- It can appear in clipboard or embedding code comparing presentation formats; record the producing interface and method.
Evidence to preserve
- Preserve both FORMATETC structures.
- Preserve registered clipboard format names.
- Preserve DVASPECT and lindex values.
- Preserve TYMED flags and target-device data.
- Preserve whether the caller expected a new advisory or cache entry.
Diagnostic sequence
- Capture the raw HRESULT
0x00040130immediately after the returning method and record whether the caller usedSUCCEEDED,FAILED, equality testing, or exception translation. - Verify the method-specific state: format, target device, aspect, index, and supported storage-medium flags are equivalent for the operation that performed the comparison.
Correct handling, retry, and recovery
Reuse the existing format relationship and avoid creating duplicate cache or advisory state. Still validate medium ownership and data freshness separately.
Practical validation scenario
A container requests an advisory for a presentation format already registered with equivalent FORMATETC fields. It accepts it, keeps one advisory, and verifies updates still reach the existing sink.
Difference from nearby HRESULT values
CACHE_S_SAMECACHE describes an existing cache entry; it focuses on equivalent data-format descriptions.
Developer and administrator guidance
References
Looking for a different code? Search another status or error code.
