How do I read a line from a .txt or .csv file in qml
I need to display a string on a simulation screen. For that I'm supposed to read the text from an existing Filename.txt/Filename.csv file.
Code:
MarqueeText {
id:scrolltext
width: 255
height: 48
anchors.verticalCenter: parent.horizontalCenter
text: //i need to display the string in text file here
}
Please help me with this. Thank you
Re: How do I read a line from a .txt or .csv file in qml
QtQuick doesn't allow you to read from files directly. You need to implement that in C++ and then transfer the result to your QtQuick runtime.