PDA

View Full Version : Qt Qml database



ganeshgladish
5th June 2013, 18:43
hi,
i have created one database..i have stored peoples in table.... whenever i retrieved people names it should display in my qml through listview...suppose if there are similate name in the listview ...if i clicked first name in the listview, it should retrieve persons details in another listview...now i have listed the persons name in first listview..now my questions is in that listview, how to access each and every persons name and that accesing means(the particular clicked persons details should be displayed in second list eview) .......


below i have provided my code ..please help me



property variant columnum:[]
ListView{
x:650;y:180
spacing: 30
width: 600;height: 500
clip:true
boundsBehavior:Flickable.StopAtBounds


model:["Title","Name","Patient-ID","Age","Contact No.","Address","Gender","DOB","Reg Date","Marital Status","Primary Doctor","Refering Doctor","History","Diagnosis","Comments"]
delegate:Row{
spacing: 30


RectangleFunction{

width: 200
color: "#00000C"
TextNames{
anchors.right: parent.right
text: ""+modelData

}
}
RectangleFunction{

TextinTable{
id:getdata123

text:columnum[index]

}



}

}
}