converto c# private string to vb.net function : I have this private string in c# make with linq that return a value found in a xml file.
I need to convet this in a vb.net function. 
I tried with c# converter but doesn't work
Can You help me please? 

this is the code.

    private string ImportoXML(string PercorsoXML, string ID)
        {
            XElement xdoc = XElement.Load(PercorsoXML, LoadOptions.PreserveWhitespace);

            string ns = xdoc.Name.Namespace.NamespaceName;

            var elements = xdoc.Elements(XName.Get("PmtInf", ns)).Elements(XName.Get("DrctDbtTxInf", ns));

            var ElencoValori = from lv2 in elements
                               select new
                               {
                                   PmtId = lv2.Element(XName.Get("DrctDbtTx", ns))
                                               .Element(XName.Get("MndtRltdInf", ns))
                                               .Element(XName.Get("MndtId", ns)).Value,
                                   InstdAmt = lv2.Element(XName.Get("InstdAmt", ns)).Value
                               };


            return ElencoValori.Where(c => c.PmtId.EndsWith(ID)).FirstOrDefault().InstdAmt.ToString();
        }

