gpt4 book ai didi

c# - 为什么 Clipboard.GetText 不起作用?

转载 作者:行者123 更新时间:2023-11-30 15:46:00 30 4
gpt4 key购买 nike

String str = Clipboard.GetText();

抛出异常

An unhandled exception of type 'System.StackOverflowException' occurred in PresentationCore.dll

如何防止这个问题?

最佳答案

你可以试试:

Clipboard.GetText(System.Windows.Forms.TextDataFormat.Text)

或者看看这里: Clipboard.GetText returns null (empty string)

http://msdn.microsoft.com/es-en/library/system.windows.forms.clipboard.gettext.aspx

关于c# - 为什么 Clipboard.GetText 不起作用?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4648718/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com