1
Vote

v1.0.2841.99 Returns rasentries with 'null'

description

VS2008 WinCE7 .Net 2.0 and 3.5

I created multiple Connections under the WinCE, Start, Settings, Network... menu.

I have 'null' in rasentry names returned from this version: v1.0.2841.99.
RasEntryCollection entryColl = Ras.Entries;
foreach (RasEntry re in entryColl)
   {
   Console.WriteLine("'" + ToStringAndAscii(re.Name) + "'");
    }

comments

empiresoftcom wrote Jan 20, 2015 at 4:10 PM

Where ToStringAndAscci is:
    public static string ToStringAndAscii(string str)
    {
        string _newstr = "";
        foreach (var c in str)
        {
            if (char.IsControl(c))
                _newstr += "{" + ((int)c).ToString() + "}";
            else
                _newstr += c;
        }
        return _newstr;
    }

empiresoftcom wrote Jan 20, 2015 at 4:12 PM

Console output:

'Bell1'
'{0}Bell2'
'0{0}Digicel'
'{0}0{0}Globalstar'

empiresoftcom wrote Jan 20, 2015 at 4:16 PM

I got version 1.0.2841.0 and it is OK.

I did some source code difference and found in RAS.cs, private static string[] EnumEntryNames() {} is different.