qModel->data(qModel->index(y,x)).type == typeid(std::string) )
this gives false and that absolutely waffles me. But never mind I used
QSqlTableModel::data to get what i need.
________________________________
From: Matthew Sherborne <[email protected]>
To: Oto Magaldadze <[email protected]>;
[email protected]
Sent: Tuesday, May 1, 2012 2:38 AM
Subject: Re: [Wt-interest] model->data handling
If what's in the boost::any variable is a string thas should work I think.
if( someValue.type() == typeid(std::string) ) {
std::string myString =
boost::any_cast<string>(qModel->data(qModel->index(y,x)));
wt::WString wtString =
boost::any_cast<string>(qModel->data(qModel->index(y,x)));
}
Haven't actually tried it though, but should get you moving in the
right direction I think.
Kind Regards,
Matthew Sherborne
On Tue, May 1, 2012 at 7:52 AM, Oto Magaldadze <[email protected]> wrote:
>
> "Wt: error during event handling: boost::bad_any_cast: failed conversion
> using boost::any_cast"------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest