I'm a newbie and I decided to enhance my program's GUI using Krypton Toolkit.
I was able to load it into my project.
The issue that I have created a control with name mycontrol
which have a KryptonDataGridView with name mydatagrid
.
In my form, I have the following code:
public partial class Form1 : KryptonForm
{
private KryptonPage[] mycontrolpage;
private Control mycontrolcontent;
public Form1()
{
InitializeComponent();
}
private KryptonPage NewmycontrolPage()
{
mycontrolcontent = new mycontrol();
KryptonPage page = new KryptonPage("mypage", null, "OS mypage");
// Add the control for display inside the page
mycontrolcontent.Dock = DockStyle.Fill;
page.Controls.Add(mycontrolcontent);
// Document pages cannot be docked or auto hidden
page.ClearFlags(KryptonPageFlags.DockingAllowAutoHidden | KryptonPageFlags.DockingAllowDocked);
return page;
}
private void Form1_Load(object sender, EventArgs e)
{
// Setup docking functionality
KryptonDockingWorkspace w = kryptonDockingManager.ManageWorkspace(kryptonDockableWorkspace);
kryptonDockingManager.ManageControl(kryptonPanel, w);
kryptonDockingManager.ManageFloating(this);
mycontrolpage = new KryptonPage[] { NewmycontrolPage() };
kryptonDockingManager.AddToWorkspace("Workspace", mycontrolpage);
}
}
My problem is how to access the grid in mycontrol
?
Without some code, You could always view the Examples.. Or Some code snippets:
Then...