create dotnetcontrol buttons inside function
I want to create buttons depending on certain things!
So here is what I need:
fn myfunction= ( ... for i=1 to IDcount do ( dotnetcontrol ID_btn[i] "System.Windows.Forms.Button" width:20 height:60 pos:[27,i*153] ID_btn[i].backcolor = (dotnetcolor 70 70 70) ID_btn[i].flatstyle = dotnetobject "System.Windows.Forms.FlatStyle" Flat ID_btn[i].text="1" ID_btn[i].foreColor = (dotnetcolor 200 200 200) ) )
How to make it work?
Comments
In this case I will use
In this case I will use dotnet Panel control and put all inside. You will lose auto alignement but who care. Just define locations of labels or buttons where you need to be inside panel control
bga
I can use even verticalString like you said
but I still could not find a solution to align buttons like in the second picture from above
Are you try with FLP
Are you try with FLP horizontal direction direction. I this not works then you need change concept
bga
Let's say
I can use image for label with vertical text - multitexture, but I can't alight buttons
Why do you want to use map to
Why do you want to use map to represent simple text.Are you try to add text to button as I show you yesterday?
bga
here is what I achieve
But these buttons are the last thing to do with GUI
May be you have some ideas how to do this:
buttons should update accordingly to textures from datagrid which change.
Here is what I have now
and here is what I want:
Are you try to use button
Are you try to use button name like this :
bga
great idea
but if I use 2 clumns FlowLayoutPanel for the buttons then how to use labels?
or should I refuse from using FlowLayoutPanel?
And how to create labels from function, to add them depending on some parameters?
Label is not different then
Label is not different then button. Define only properties for backcolor,forecolor,textalign,...
bga