程序在Windows 10上共享屏幕问题 [英] Program to share screen issue on Windows 10

查看:566
本文介绍了程序在Windows 10上共享屏幕问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述








我们使用RDPCOM实现一个屏幕共享工具APILIB.dll,包括两个应用程序主机和查看器。查看器通过axRDPViewer.Connect连接到主机(viewerTicket,myName,"");





参数viewerTicket由tcp消息发送,myName与两个字符串"name"相结合。和"id",哪个分隔符是"\f"(Form Feed 0x0c),因此该值可能类似于"myViewer \ f14"。







它在Windows 7上运行良好,当我们在Windows 10(RS3)上同时尝试主机和查看器时,结果是不同的,如果"名称"在包含超过8个字符,否则会弹出错误消息"您的远程桌面
连接失败,因为远程计算机无法通过身份验证"并失败了。







为了与早期的应用程序兼容,很难修改参数。



你能告诉我问题出在哪里,如何我们可以照顾它吗?

解决方案

您好NewSofyXA,


感谢您在此发帖。


对于您的问题,您可以尝试做出判断。如果Windows系统是Win10,它将返回true,并使用Win7中的不同字符。

 static bool IsWindows10()
{
var reg = Registry.LocalMachine.OpenSubKey(@"SOFTWARE \ Microoft \ Windows NT \ CurrentVersion");

string productName =(string)reg.GetValue(" ProductName");

返回productName.StartsWith(" Windows 10");
}

我测试代码。如果我在Win10中运行,则返回true,否则返回false(我在Win7中测试)。


最好的问候,


Wendy


Hi,

We implement a screen sharing tool using RDPCOMAPILIB.dll, which include two applications host and viewer. The viewer connect to the host by axRDPViewer.Connect(viewerTicket, myName, "");


The argument viewerTicket is sent by tcp message, and myName is combined with two strings "name" and "id", which separator character is "\f"(Form Feed 0x0c), so the value may like this "myViewer\f14".


It works well on Windows 7, when we try both host and viewer on Windows 10(RS3), the result are different, if the "name" include more than 8 characters it works, otherwise it pops an error message "Your remote desktop connection failed because the remote computer cannot be authenticated" and failed.


for compatible with earlier application, it is hard to modify the arguments.

Can you teach me where is the problem, How can we take care of it?

解决方案

Hi NewSofyXA,

Thank you for posting here.

For your question, you could try make a judgement. If the Windows system is Win10, it will return true, and use the different characters with Win7.

static bool IsWindows10()
        {
            var reg = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows NT\CurrentVersion");

            string productName = (string)reg.GetValue("ProductName");

            return productName.StartsWith("Windows 10");
        }

I test the code. If I run in Win10, it return true, otherwise, return false (I test in Win7).

Best Regards,

Wendy


这篇关于程序在Windows 10上共享屏幕问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆