Your code is quite complex for such a simple problem so, let's break it in pieces.
First of all, you need a method which will return the attribute values for the elements you pass as argument
private IEnumerable<string> GetAttributeValuesForElements(IEnumerable<string> elementNames)
{
var document = XDocument.Load("path-to-your-xml");
var results = document.Descendants(myXml.siteName)
.Join(elementNames,
element => element.Elements().First().Value,
name => name,
(element, name) => element.Attribute(myXml.sitePath).Value);
return results;
}
Second of all, you need a method which will return the selected names from the listbox:
private IEnumerable<string> GetSelectedNames(Listbox listbox)
{
foreach(var item in listbox.CheckedItems)
yield return item.ToString();
}
Now, put those two together in your event handler:
private void Submit_btn_Click(object sender, EventArgs e)
{
var selected = GetSelectedNames(serverLISTbox);
var attributes = GetAttributeValuesForElements(selected);
// do stuff with the attributes.
}
Hope this helps...