Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(PlatformException(Clipboard error, Unable to open clipboard, 5, null) #10

Open
keith555 opened this issue Jun 8, 2023 · 3 comments
Open

Comments

@keith555
Copy link

keith555 commented Jun 8, 2023

PlatformException (PlatformException(Clipboard error, Unable to open clipboard, 5, null))

I'm getting this error on Windows 11 Home running the example app. It sometimes throws the error on the first copy, sometimes after one or two successful copies. I don't know if this is related.

@peyman1959
Copy link

I have the same problem
[ ] #0 JSONMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:171:7) [ ] #1 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:310:18) [ ] <asynchronous suspension> [ ] #2 Clipboard.getData (package:flutter/src/services/clipboard.dart:52:42) [ ] <asynchronous suspension>

@aa2013
Copy link

aa2013 commented Apr 4, 2024

PlatformException (PlatformException(Clipboard error, Unable to open clipboard, 5, null))

I'm getting this error on Windows 11 Home running the example app. It sometimes throws the error on the first copy, sometimes after one or two successful copies. I don't know if this is related.

This error may occur when there are other applications simultaneously accessing the clipboard, and the previous program has not released the clipboard lock, resulting in inability to acquire the lock.

@aa2013
Copy link

aa2013 commented Apr 4, 2024

You can independently implement the corresponding platform method and then add a delayed retry mechanism, which can basically eliminate the problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants