I am developing a program in Visual Basic.NET for a class that I am taking and I would like to see if I can get...
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
some guidance. What I am doing is developing a program where I can take a class A,B, or C IP address and Subnet form that address. I will need to verify subnet masks, and develop the formula to Subnet. I am new to this and have reached a barrier here on this portion of the program. Any help would be greatly appreciated. I'm not exactly sure what the goal of the application is, because I'm not sure what you mean by "formula to subnet." Well, I'm sure they want you to perform some binary calculation on the IP address. Your best bet is probably to use, and possibly extend, the System.Net.IPAddress class. Here's the related page in MSDN: http://msdn.microsoft.com/library/en-us/cpref/html/frlrfsystemnetipaddressclasstopic.asp.
You can use the IPAddress.Parse() method to accept a standard x.x.x.x IP address format, and then use GetAddressBytes() to get the IP address' four bytes for binary processing.
Dig Deeper on Windows Operating System Management
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.