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 » Accessing controls in layout within ArrayCtrl
Re: Accessing controls in layout within ArrayCtrl [message #35036 is a reply to message #35030] Sun, 01 January 2012 10:37 Go to previous messageGo to previous message
Sender Ghost is currently offline  Sender Ghost
Messages: 301
Registered: November 2008
Senior Member
Hello.

unknown wrote on Fri, 30 December 2011 13:24

How to access single controls of an ArrayCtrl entry?


It depends on how you create ArrayCtrl column(s). In the following case:
ArrayCtrl list;
// ...
list.AddColumn("Composite").Ctrls<CompositeCtrl>();
list.SetLineCy(CompositeCtrl::GetLayoutSize().cy);

unknown wrote on Fri, 30 December 2011 13:24

Let's say I have a text box on the third row of the ArrayCtrl, how would I add a text to it later on in my code?


// CompositeCtrl at third row and second column
CompositeCtrl *ctrl = static_cast<CompositeCtrl *>(list.GetCtrl(2, 1));

if (ctrl)
	ctrl->text <<= "Some text";


The full example you could find in the attachments.
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: U++ App for linux
Next Topic: First time with upp
Goto Forum:
  


Current Time: Sun May 05 13:55:57 CEST 2024

Total time taken to generate the page: 0.02298 seconds