我转换这个权利...... [英] Am I converting this right...

查看:58
本文介绍了我转换这个权利......的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我将字符串转换为二进制数,功能为

Hi All,

I am converting a string to a binary number with the function

BinaryVersionSerialNumber = Convert.ToString(SerialNumber, 2);

这似乎给出了一个二进制数,我可以把它放在SerialNumber的形式上,这是一个Int32(我认为是一个32位整数)我得到了很多帮助的转换工作昨天来自CPallini,然而逆转野兽让我有点困惑,我正在假设X'=(X ^ Y),会让你做X =(X'^ Y),但它没有好像。我的逻辑错误还是转换为二进制文件?





格伦(我需要更多咖啡!)



谢谢你建议,见下面的评论。我现在遇到的问题是如果执行按位运算

This appears to give a binary number which I can put on the form the SerialNumber which is an Int32 (a 32 bit integer I think) I got the conversion to work with a lot of help yesterday from CPallini, However reversing the beast has got me a little confused, I was working on the assumption that X' = (X^Y), would allow you to do X = (X'^Y), but it doesn't seem to. Is my logic wrong or has the conversion to binary broken ?


Glenn (I need more coffee!)

Thanks for the advice, see comments below. The issue I have now is if performing the bitwise operation

Result = PassCode;
          MessageBox.Show(Result.ToString());

          Result = (Result & 0xFFF00000);
          MessageBox.Show(Result.ToString());



结果从给出0的字符串中清除,看来int32是结果

当它是'和'用六角填料给出0.我有点困惑吗?

格伦


Result is cleared from the string giving 0, it would appear that the int32 that is Result
when it is 'and' with the Hex filler gives 0. I am a little confused by this?
Glenn

推荐答案

这篇关于我转换这个权利......的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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