Java to C# code converter
<p>Are there any converters available that converts Java code to C#?</p>

<p>I need to convert the below code into C#</p>

<pre><code>String token = new String(""); 
URL url1 =new URL( "http", domain, Integer.valueOf(portnum), "/Workplace/setCredentials?op=getUserToken&amp;userId="+username+"&amp;password="+password +"&amp;verify=true"); 
URLConnection conn1=url1.openConnection(); 
((HttpURLConnection)conn1).setRequestMethod("POST"); 
InputStream contentFileUrlStream = conn1.getInputStream(); 
BufferedReader br = new BufferedReader(new InputStreamReader(contentFileUrlStream)); 
token=br.readLine(); 

String encodedAPIToken = URLEncoder.encode(token); 
String doubleEncodedAPIToken ="ut=" + encodedAPIToken;//.substring(0, encodedAPIToken.length()-1); 
//String doubleEncodedAPIToken ="ut=" + URLEncoder.encode(encodedAPIToken); 
//String userToken = "ut=" + URLEncoder.encode(token, "UTF-8"); //URLEncoder.encode(token); 
String vsId = "vsId=" + URLEncoder.encode(docId.substring(5, docId.length()), "UTF-8"); 
url="http://" + domain + ":" + portnum + "/Workplace/getContent?objectStoreName=RMROS&amp;objectType=document&amp;" + vsId + "&amp;" +doubleEncodedAPIToken; 
String vsId = "vsId=" + URLEncoder.encode(docId.substring(5, docId.length()), "UTF-8"); 
url="http://" + domain + ":" + portnum + "/Workplace/getContent?objectStoreName=RMROS&amp;objectType=document&amp;" + vsId + "&amp;" +doubleEncodedAPIToken; 
</code></pre>

<p>Thanks in advance</p>
