Kotlin File.readtext() call crashes Android app
My Kotlin/Android Studio function (below) crashes my app when it hits the line that begins with: "val xmlInput = InputSource...". It's my first attempt to read an xml resource file into an app using Kotlin, so probably I'm missing something that should be obvious...?
fun readXml(xlmFileLoc : String): InputSource { // e.g. "./raw/norms.xml"
val xmlFile = File(xlmFileLoc)
val dbFactory = DocumentBuilderFactory.newInstance()
// return dbFactory // SUCCESS!
val...