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 » U++ Widgets - General questions or Mixed problems » ArrayCtrl with labels / layouts inside ?
Re: ArrayCtrl with labels / layouts inside ? [message #12891 is a reply to message #12890] Mon, 26 November 2007 18:06 Go to previous messageGo to previous message
Oblivion is currently offline  Oblivion
Messages: 1210
Registered: August 2007
Senior Contributor
If I understood you right, try using myArray.SetCtrl()


Below is the modified code of Arrayctrl reference example.


ArrayCtrlExample::ArrayCtrlExample()
{
	CtrlLayoutExit(*this, "ArrayCtrl example");
	

	array.AddColumn("integer").Sorting();
	array.AddIndex(ID1);
	array.AddColumn(ID2, "combined").Add(ID1).AddIndex(ID3).SetConvert(Single<MyConvert>());
	array.AddColumn("editable").Edit(myedit).Sorting();
	array.AddColumn("with display").SetDisplay(Single<MyDisplay>());
	array.AddCtrl(editor);
	array.AddRowNumColumn("rownum");
	array.WhenLeftDouble = THISBACK(DoubleClick);
	array.ColumnWidths("51 120 60 102 62");

	for(int i = 0; i < 20; i++)
		array.Add(i, AsString(i * 10), GetSysDate(), i * 3, rand() % 1000,
		          Color(byte(i * 77), byte(i * 200), byte(i * 135)), FormatIntRoman(i));
//==========================================================
	bt.SetLabel("Test"); // bt should be declared in the interface
	array.SetCtrl(2, 2, bt);
//==========================================================
}



Just overwrite the original code, and declare "Button bt" before compiling, and see what it does.
Smile


[Updated on: Mon, 26 November 2007 18:10]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: How to use WithDropChoice?
Next Topic: PromptOK - little error in textselection
Goto Forum:
  


Current Time: Mon Jun 09 10:22:44 CEST 2025

Total time taken to generate the page: 0.04179 seconds