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 #45610 is a reply to message #45589] Tue, 15 December 2015 22:19 Go to previous messageGo to previous message
mr_ped is currently offline  mr_ped
Messages: 825
Registered: November 2005
Location: Czech Republic - Praha
Experienced Contributor
			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)));


pardon my ignorance (and laziness to check the zip with full source), but is it ok the for has "j" and the Set takes "i" in first parameter?

Also when the key is "AsString(query[DRUM])", you may produce string like "i,query[DRUM]" for keys, and then extract the query[DRUM] by splitting the key with ',', if you insist to have that data encoded in key. Just an option, I would probably consider in PHP (where the thing is slow as hell already anyway, and writing str manipulation is easy too)... but in U++ I think having a vector with query[DRUM] values around and using pure "i" (or j?) is easier to write, read and maintain...
 
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 11:12:20 CEST 2024

Total time taken to generate the page: 0.02922 seconds