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 » Community » Newbie corner » Problem using a switch control
Re: Problem using a switch control [message #45603 is a reply to message #45599] Mon, 14 December 2015 20:49 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13980
Registered: November 2005
Ultimate Member
Giorgio wrote on Mon, 14 December 2015 15:08
Hello Mirek,
thank you for your post. I have used the debugger and it seems switch cases have different values. In fact, the value is assigned during a loop with a variable that is incremented. Anyway, I created a very small test case, attached. Please note that the test case is very small, most of the space is the sqlite db. As my application uses a MySQL db, I have created a sqlite db: please note that I got rid of a lot of tables, so maybe the db and application look incoherent. To reproduce the problem, launch the application and click on the "Select job order" button. A dialog opens: put in the active field the following order id 15036120901 (maybe it works with other order ids, but I tested that one) and hit return. After that, click on a switch case and then pass the mouse over other cases (try different cases, sometimes it works with a particular case). The problem is in lines 51-85 (specifically, lines 62-77), but I cannot locate it.
Thank you for the support,
Gio


			for(int j = 0; j < n_of_drums; j++)
			{
				DDUMP(query[DRUM]);
				dlgSelectDrums.lengthList.Set(i, AsString(query[DRUM]), ( AsString(query[METER]) + "m - N: " + AsString(k+1) + " of " + AsString(n_of_drums)));


query[DRUM] = 125
query[DRUM] = 125
query[DRUM] = 125
query[DRUM] = 140
query[DRUM] = 160
query[DRUM] = 160


...exactly what I have suspected...
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Multiple lines on EditString
Next Topic: Installation Problem in OpenSUSE Tumbleweed
Goto Forum:
  


Current Time: Thu May 16 08:19:57 CEST 2024

Total time taken to generate the page: 0.01662 seconds