FAQ - VB to C sharp net guide

Question
cannot convert from 'string' to 'char[]'
Answer

You've used  http://www.developerfusion.com/tools/convert/vb-to-csharp/ whist its done a fairly good job there are some errors which need your attention...

 

So I get this error message:

cannot convert from 'string' to 'char[]'

 

So what is the problem? Most likely its that "xyz" is defined as a character where the variable 'xyz' note the single quotes is designnated as a string.

 

Hardcoded (single) character value:  " x "

Hardcoded string value:  ' x '

 

Other conventions that may trap the experienced vb programmer

 

If you found this information useful, please share it!


This FAQ was last updated on 21 July 2011

Contact Information

To find out more about Ava solutions you can contact us in a number of ways:
Follow Us...