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 » DropGrid problem in 1254?
DropGrid problem in 1254? [message #21780] Thu, 04 June 2009 23:03 Go to next message
jeremy_c is currently offline  jeremy_c
Messages: 175
Registered: August 2007
Location: Ohio, USA
Experienced Member
I have a DropGrid that's pretty simple... It's defined in the associated Layout w/all default options. In code I:

apiary.AddPlus(THISBACK1(NewApiary, &apiary));
apiary.WhenAction = THISBACK(OnChangeApiary);

// Later in code, I populate it:
apiary.Clear();
apiary.Add(0, "All");
	
SQL & Select(ID.Of(APIARY), NAME.Of(APIARY))
    .From(APIARY)
    .OrderBy(NAME.Of(APIARY));

    while(SQL.Fetch())
        apiary.Add(SQL[0], SQL[1]);

// Later in code:

void BeekPRO::OnChangeApiary()
{
	LoadHives(apiary.GetData());
}

void BeekPRO::LoadHives(Value apiaryId)
{
    hives.Clear();
	
    if (apiaryId == 0)
        SQL & Select(ID, APIARY_ID, NAME, HIVE_TYPE_ID)
            .From(HIVE)
            .OrderBy(NAME);
    else
        SQL & Select(ID, APIARY_ID, NAME, HIVE_TYPE_ID)
            .From(HIVE)
            .Where(APIARY_ID == apiaryId)
            .OrderBy(NAME);
	
    while(SQL.Fetch())
        hives.Add(SQL);
}


That's all the code related to this drop grid. The problem I am having is when I change the selection of the drop grid, the hives grid is reloaded properly however the display of the newly selected apiary is blank. If I simply move my mouse over the control the control then changes from blank to the apiary name.

If I simply load U++ 2008.1 and compile the program, I do not have this problem. Everything runs find and updates instantly. When I then load it in 1254, recompile the bug exists. Load in 2008.1, recompile everything works great.

I've tried to reproduce this in a small test case but have failed.

Has anyone else experienced this?

Jeremy
Re: DropGrid problem in 1254? [message #21781 is a reply to message #21780] Thu, 04 June 2009 23:22 Go to previous messageGo to next message
unodgs is currently offline  unodgs
Messages: 1366
Registered: November 2005
Location: Poland
Ultimate Contributor

Please get latest sources from svn. I reverted removing SetFoucs from DropGrid. Now everything should work as before. Sorry for troubles.
Re: DropGrid problem in 1254? [message #21785 is a reply to message #21781] Fri, 05 June 2009 00:57 Go to previous message
jeremy_c is currently offline  jeremy_c
Messages: 175
Registered: August 2007
Location: Ohio, USA
Experienced Member
unodgs wrote on Thu, 04 June 2009 17:22

Please get latest sources from svn. I reverted removing SetFoucs from DropGrid. Now everything should work as before. Sorry for troubles.


Yes, this works now. Thanks and no problem, we're developers we write bugs once or twice in our career Smile

Jeremy
Previous Topic: Gridctrl and colors
Next Topic: DropDate in GridCtrl ... Howto populate on insert?
Goto Forum:
  


Current Time: Fri Mar 29 07:21:34 CET 2024

Total time taken to generate the page: 0.01402 seconds