DATAGRID IN USER CONTROL

  • Thread starter Thread starter Hardik Shah
  • Start date Start date
H

Hardik Shah

Cor,

When I wrote above code , it displays error at design time (blue line),


Hardik

Hardik,

What do you mean with fail? With the code that you show you can set a tablestyle using a property. (However it does for the rest nothing).

Cor
 
Hi,

I want to create a UserControl using DataGrid,ComboBox and DataTimePicker Control. I want to DataGrid's TableStyle Collection at user Level. I wrote following lines on my user control, but it is fail.

Private _DtGrTableStyle As TableStyles

Public Property DtGrTableStyle() As TableStyles

Get

Return _DtGrTableStyle

End Get

Set(ByVal Value As TableStyles)

_DtGrTableStyle = Value

Invalidate()

End Set

End Property

What is wrong ?

Any hint will be sincerely appreciated.

Hardik Shah.
 
Hardik,

What do you mean with fail? With the code that you show you can set a tablestyle using a property. (However it does for the rest nothing).

Cor
 
Hardik,

And when you delete this code does the form in design time than again shows
well?

Cor
 
Hi,

I think I can't explain my question effectively, So I repeat it in brief.

I create a UserControl using DataGrid,ComboBox and DataTimePicker Control.
I want to use following propery at user level.
1) Combobox's => datasource,value member etc.
2) DateTimePickers => Value
3) DataGrid's => TableStyles Collection

I write following commands at usercontrol

--------------------------------------------------------------------------------


Private _DtGrTableStyle As TableStyles

Public Property DtGrTableStyle() As TableStyles

Get

Return _DtGrTableStyle

End Get

Set(ByVal Value As TableStyles)

_DtGrTableStyle = Value

Invalidate()

End Set

End Property
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top