How can i use linq to xml in F# to extract all specific tags from an XML file.
Open the file
let Bookmarks(xmlFile:string) =
let xml = XDocument.Load(xmlFile)
Once i have the XDocument how can I navigate it using Linq to XML?
can someone point me in the right direction ?
Edit: Part of my solution
let xname (tag:string) = XName.Get(tag)
let tagUrl (tag:XElement) = let attribute = tag.Attribute(xname "href")
attribute.Value
let Bookmarks(xmlFile:string) =
let xml = XDocument.Load(xmlFile)
xml.Elements <| xname "A" |> Seq.map(tagUrl)