当前位置:编程学习 > C#/ASP.NET >>

Winfrom中制作复制,粘贴的问题,求大神帮助。。。谢谢

我在RichTextBox中放了一个拉框,制作复制,粘贴,的功能。
但是我测试的时候出现提示:在可以调用 OLE 之前,必须将当前线程设置为单线程单元(STA)模式。请确保您的 Main 函数带有 STAThreadAttribute 标记。希望看到的大神帮忙解决一下。。。。。谢谢! 复制制作,粘贴制作 --------------------编程问答--------------------
这个是截图 --------------------编程问答--------------------  [STAThread]
        static void Main()
看看你的是不是这样。如果不是就改成这样。 --------------------编程问答-------------------- static class Program
    {
        /// <summary>
        /// 应用程序的主入口点。
        /// </summary>
        [STAThread]
        static void Main()

错误提示的已经很明显了吧 --------------------编程问答-------------------- 关键是我的主程序处有这句啊!
static class Program
    {
        /// <summary>
        /// 应用程序的主入口点。
        /// </summary>
        /// 

        [STAThread]
        static void Main()
        {
           //。。。。
         } --------------------编程问答-------------------- 除
补充:.NET技术 ,  C#
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,