views:

129

answers:

2

Hi,

I've been looking on the internet for 4 hours and I just can't do it.

My objectives : create a combo where I can sort my items and when I click on one of them, the item appears alone.

In Excel, easy to do, but I can't do it in C#.

I found this answer : Other topic, but I can't understand where the "this.Controls" comes from.

Thanks for your help

A: 

I can't really help you with the Excel question but the this.Controls comes most probably from a Windows Forms application. See this article on MSDN. You can try it by creating an empty Windows Forms application and then typing in the Form1.cs this.Controls.

Radoslav Hristov
A: 

I found by myself, trying random stuffs :

Range m_range = Sheet.get_Range("A1", "F9"); m_range.AutoFilter(1, Missing.Value,XlAutoFilterOperator.xlAnd, Missing.Value, true);

I don't really know why, but the result is perfect, the top row is used as the header, and all the other cells are added... Cool

Rippalka