should contain all that you need, and is much easier to parse. Only problem would be share names with commas in them, but for a reason unbeknownst to me, these are much rarer than those with embedded spaces :-)

There are several such command line utilities whose output is inconsistent or not parseable without mind reading capabilities. In such cases one should look for alternative sources of input.

Parsing the output of WMIC looks even more difficult , cause its output is very different as compared to net use. So If u could tell me how to parse it or break it into what i need, it would be a great help..