Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » ArrayCtrl, HeaderCtrl & GridCtrl » GridCtrl Serialize problem and solution
GridCtrl Serialize problem and solution [message #28733] Tue, 14 September 2010 11:36 Go to next message
koldo is currently offline  koldo
Messages: 3355
Registered: August 2008
Senior Veteran
Hello unodgs

Using Serialize with GridCtrl I get an exception the first time the app. is opened.

The reason is that in GridCtrl::Serialize() function, there is this:

	else
	{
		int tc;
		s % tc;
		for(int i = 1; i < tc; i++)
		{
			//String alias;
			//s % alias;
			//int n = aliases.Find(alias);
			int id;
			s % id;
			//if(id >= 0 && id < total_cols)
			s % hitems[id];
		}
	}


As the first time, id value is undefined so I get an exception in s % hitems[id];.

Uncommenting line //if(id >= 0 && id < total_cols), the problem is solved.


Best regards
Iñaki
Re: GridCtrl Serialize problem and solution [message #28816 is a reply to message #28733] Fri, 17 September 2010 23:12 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3355
Registered: August 2008
Senior Veteran
Rolling Eyes

Best regards
Iñaki
Re: GridCtrl Serialize problem and solution [message #28820 is a reply to message #28816] Sat, 18 September 2010 00:45 Go to previous messageGo to next message
unodgs is currently offline  unodgs
Messages: 1366
Registered: November 2005
Location: Poland
Ultimate Contributor

Of course you're right Koldo. But there was a deeper problem with Serialize (that's why most of the code is commented) - I must refresh my memory what was it Smile. Anyway please keep your fix locally and I'll try ASAP to make Serialize method working again.
Re: GridCtrl Serialize problem and solution [message #28826 is a reply to message #28820] Sat, 18 September 2010 13:15 Go to previous message
koldo is currently offline  koldo
Messages: 3355
Registered: August 2008
Senior Veteran
unodgs wrote on Sat, 18 September 2010 00:45

Of course you're right Koldo. But there was a deeper problem with Serialize (that's why most of the code is commented) - I must refresh my memory what was it Smile. Anyway please keep your fix locally and I'll try ASAP to make Serialize method working again.

Thank you.


Best regards
Iñaki
Previous Topic: GridCtrl - how to perform multiselect via CTRL like in ArrayCtrl
Next Topic: It's a little strange for zooming GridCtrl column layout width
Goto Forum:
  


Current Time: Thu Mar 28 21:49:35 CET 2024

Total time taken to generate the page: 0.01486 seconds