Advertisement
4_2005-2006 Miscellaneous #157249

Dear Planet Source Code Users

Please read. Ian likes this letter by me.

AI

Yapay Zeka Özeti: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.

Kaynak Kod
original-source
Dear Planet-Source-Code users:
<br>	Hello there! I am writing this letter to inform you of somethings and warn you about my concerns. I have asked Ian not to delete this post or allow it to be deleted. I know a lot of you already follow what I am going to tell you. I thank you for that. For the others, I believe it is time for you to shape up.
<br>	As I am tired of many repeat, silly, common-sense, and just plain s tupid posts here on Planet Source Code, I believe you are to. Some people try to post quality work on this wonderful site, but others simply destroy the beauty of it by posting pure garbage. Most of the garbage is "decorated" by using "best code ever". Clearly this is a lie. Usally in Visual Basic its just an End statement, a Kill statement, a message box, or just something that has no code. Also, some of the garbage on Planet Source Code is just people asking questions. There is a place for that, ether in the fourms or in the code itself. Why don't those people ask elsewhere? In addition, I have seen people uploading zip files that don't have code. I have seen this in game engines, they just provide a link to the source on their own site. Don't waste space with that. Also, I have seen a lot of incomplete submissions. I cannot tell you how many submissions I have downloaded that are incomplete. I just downloaded one today that did not have the control. I figured he tried to upload the OCX, but he forgot to read "Planet Source Code does not accept: ... Compiled .Exe's, .Dll's, .Ocx's (these are automatically deleted from submissions to prevent viruses. If you MUST upload one of these, email [email protected] with an explanation why.)". Ha! 
Some people for get to give all the files. I have seen submissions without the solutions, project files, the ResX files, the control files, and the form files. And sometimes the project path is declared absolutly, not reltivily. So sometimes in order for a project to work, I have to load every stinking file. This is only the begining.
<br>	Now that is not even all the serious of my letter. I have seen people being stalked by people who are just plain mean by voting low on all their work. I have seen people hate people's project names. This is serious folks.
<br>	I hope you all read this letter and take heart to it. It is important that we do our best and keep Planet Source Code clean!
<br>
The New iSoftware Company
Imports Microsoft.Win32
Module modXPKey
  Public Function sGetXPKey() As String
    'Open the Registry Key and then get the value (byte array) from the SubKey
    Dim RegKey As RegistryKey = _
      Registry.LocalMachine.OpenSubKey("Software\Microsoft\Windows NT\CurrentVersion", False)
    Dim bytDPID() As Byte = RegKey.GetValue("DigitalProductID")
    'Transfer only the needed bytes into our Key Array
    ' Key starts at byte 52 and is 15 bytes long.
    Dim bytKey(14) As Byte '0-14 = 15 bytes
    Array.Copy(bytDPID, 52, bytKey, 0, 15)
    'Our "Array" of valid CD-Key characters
    Dim strChar As String = "BCDFGHJKMPQRTVWXY2346789"
    'Finally, our decoded CD-Key to be returned
    Dim strKey As String = ""
    'How Microsoft encodes this to begin with, I'd love to know...
    'but here's how we decode the byte array into a string
    'containing the CD-KEY.
    For j As Integer = 0 To 24
      Dim nCur As Short = 0
      For i As Integer = 14 To 0 Step -1
        nCur = CShort(nCur * 256 Xor bytKey(i))
        bytKey(i) = CByte(Int(nCur / 24))
        nCur = CShort(nCur Mod 24)
      Next
      strKey = strChar.Substring(nCur, 1) & strKey
    Next
    'Finally, insert the dashes into the string.
    For i As Integer = 4 To 1 Step -1
      strKey = strKey.Insert(i * 5, "-")
    Next
    Return strKey
  End Function
End Module
Orijinal Yorumlar (3)
Wayback Machine'den kurtarıldı