Key Finder Application ( Windows) in C # Vs2010PApuneet ahooja11yAsked Jan 11, 2016, 1:00 AM EST2 answersShareLinkedInXCopy linkSaveDear Friends, Please Tell me how to make a key finder application (Windows) in C # Vs 2010 step by step with screen shots. RegardsPuneet Ahooja
Key Finder Application ( Windows) in C # Vs2010PApuneet ahooja11yAsked Jan 11, 2016, 1:00 AM EST2 answersShareLinkedInXCopy linkSaveDear Friends, Please Tell me how to make a key finder application (Windows) in C # Vs 2010 step by step with screen shots. RegardsPuneet Ahooja
Arul RRank #2,478 · 566 reputation11y agoPosted Jan 11, 2016, 3:59 AM EST0Kindly refer the below links, Hope this will solve your problem. http://www.codeproject.com/Articles/23334/Microsoft-Product-Key-Finder Let me know for any thing more.... If your problem solved means kindly Accept my answer0
PApuneet ahooja61 reputation11y agoPosted Jan 15, 2016, 2:21 AM EST0Dear Friend, According to the above mentioned article, I want to make this key finder application for learning but it showing error. Article No: http://www.codeproject.com/Articles/23334/Microsoft-Product-Key-Finder Error Is: with Red Marking class KeyDecoder { public enum Key { XP, Office10, Office11 }; public static byte[] GetRegistryDigitalProductId(Key key) { byte[] digitalProductId = null; RegistryKey registry = null; switch (key) { // Open the XP subkey readonly. case Key.XP: registry = Registry.LocalMachine. OpenSubKey( @"SOFTWARE\Microsoft\Windows NT\CurrentVersion", false); break; // Open the Office 10 subkey readonly. case Key.Office10: registry = Registry.LocalMachine. OpenSubKey( @"SOFTWARE\Microsoft\Office\10.0\Registration\" + @"{90280409-6000-11D3-8CFE-0050048383C9}", false); // TODO: Open the registry key. break; // Open the Office 11 subkey readonly. case Key.Office11: // TODO: Open the registry key. break; } if (registry != null) { // TODO: For other products, key name maybe different. digitalProductId = registry.GetValue("DigitalProductId") as byte[]; registry.Close(); } return digitalProductId; } public static string DecodeProductKey(byte[] digitalProductId) { // Offset of first byte of encoded product key in // 'DigitalProductIdxxx" REG_BINARY value. Offset = 34H. const int keyStartIndex = 52; // Offset of last byte of encoded product key in // 'DigitalProductIdxxx" REG_BINARY value. Offset = 43H. const int keyEndIndex = keyStartIndex + 15; // Possible alpha-numeric characters in product key. char[] digits = new char[] { 'B', 'C', 'D', 'F', 'G', 'H', 'J', 'K', 'M', 'P', 'Q', 'R', 'T', 'V', 'W', 'X', 'Y', '2', '3', '4', '6', '7', '8', '9', }; // Length of decoded product key const int decodeLength = 29; // Length of decoded product key in byte-form. // Each byte represents 2 chars. const int decodeStringLength = 15; // Array of containing the decoded product key. char[] decodedChars = new char[decodeLength]; // Extract byte 52 to 67 inclusive. ArrayList hexPid = new ArrayList(); for (int i = keyStartIndex; i <= keyEndIndex; i++) { hexPid.Add(digitalProductId[i]); } for (int i = decodeLength - 1; i >= 0; i--) { // Every sixth char is a separator. if ((i + 1) % 6 == 0) { decodedChars[i] = '-'; } else { // Do the actual decoding. int digitMapIndex = 0; for (int j = decodeStringLength - 1; j >= 0; j--) { int byteValue = (digitMapIndex << 8) | (byte)hexPid[j]; hexPid[j] = (byte)(byteValue / 24); digitMapIndex = byteValue % 24; decodedChars[i] = digits[digitMapIndex]; } } } return new string(decodedChars); } } } Aplication form Like This Windows Office Key Form Load Event Code is as mentioned in Article no. 23334: private void Form1_Load(object sender, EventArgs e) { byte[] results1 = KeyDecoder.GetRegistryDigitalProductId(KeyDecoder.Key.XP); textBox1.Text = KeyDecoder.DecodeProductKey(results1); byte[] results2 = KeyDecoder.GetRegistryDigitalProductId(KeyDecoder.Key.Office10); textBox2.Text = KeyDecoder.DecodeProductKey(results2); } }} Please help RegardsPuneet Ahooja 0Join to answer this questionEvery answer you publish earns 20 SHARP.Create free accountSign inKnow the answer?Answer a question in the forums and earn +20 SHARP for every answer.See unanswered questionsForumsTop experts01Arun PottiAnswers in the forums20answers02Tahir AnsariAnswers in the forums5answers03Kamlesh KumarAnswers in the forums5answers04Sam HobbsAnswers in the forums4answers05Željko PerićAnswers in the forums3answers?YouYour name goes here.Every answer: 20 SHARP.JoinFull leaderboard →2026DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Arul RRank #2,478 · 566 reputationPosted Jan 11, 2016, 3:59 AM EST
puneet ahooja61 reputationPosted Jan 15, 2016, 2:21 AM EST
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questionsTop experts