Click here to Skip to main content
15,886,873 members
Home / Discussions / C#
   

C#

 
QuestionBHO not gets injected? Pin
svt gdwl4-Jun-09 20:19
svt gdwl4-Jun-09 20:19 
AnswerThis is the error occured during installation Pin
svt gdwl4-Jun-09 21:14
svt gdwl4-Jun-09 21:14 
QuestionEquivalent C# 2.0 code Pin
Ankit Rajpoot4-Jun-09 18:56
Ankit Rajpoot4-Jun-09 18:56 
AnswerRe: Equivalent C# 2.0 code Pin
Christian Graus4-Jun-09 21:40
protectorChristian Graus4-Jun-09 21:40 
QuestionHow to type special character such as √ ,Π in C#? Pin
tannghia4-Jun-09 17:19
tannghia4-Jun-09 17:19 
AnswerRe: How to type special character such as √ ,Π in C#? Pin
Christian Graus4-Jun-09 17:32
protectorChristian Graus4-Jun-09 17:32 
QuestionAutoscroll DataGridview Control Pin
Member 20251764-Jun-09 16:07
Member 20251764-Jun-09 16:07 
AnswerRe: Autoscroll DataGridview Control Pin
Niladri_Biswas4-Jun-09 16:25
Niladri_Biswas4-Jun-09 16:25 
It can be achieved by setting the overflow style to scroll of the div tag.

<div style="overflow:scroll;width:40%;height:40%">


e.g.

The grid view in the .aspx is like this

<div style="overflow:scroll;width:30%;">
      <asp:GridView ID="gvDetail" runat="server" AutoGenerateColumns="False" 
            HeaderStyle-BackColor="gray" AlternatingRowStyle-BackColor="GreenYellow "
            BackColor="white" BorderColor="blue" BorderStyle="None" Width="80%">
        <Columns> 
        
        <asp:BoundField DataField="UserId" HeaderText="User Id">
        <ItemStyle HorizontalAlign="Left" Width="80%" />
        </asp:BoundField>
        
        <asp:BoundField DataField="Name" HeaderText="User Name">
        <ItemStyle HorizontalAlign="Left" Width="80%" />
        </asp:BoundField>
        
        
        <asp:BoundField DataField="Age" HeaderText="User Age">
        <ItemStyle HorizontalAlign="Left" Width="40%" />
        </asp:BoundField>
        
        <asp:BoundField DataField="Address" HeaderText="User Address">
        <HeaderStyle Wrap="true"></HeaderStyle>
        
        <ItemStyle HorizontalAlign="Left" Width="10%" Wrap="true" />
        </asp:BoundField>
        
         <asp:BoundField DataField="Sex" HeaderText="User Sex">
        <ItemStyle HorizontalAlign="Left" Width="10%" />
        </asp:BoundField>
        
        <asp:BoundField DataField="DOB" HeaderText="User DOB">
        <ItemStyle HorizontalAlign="Left" Width="10%" />
        </asp:BoundField>
        
        <asp:BoundField DataField="Year" HeaderText="User Year">
        <ItemStyle HorizontalAlign="Left" Width="10%" />
        </asp:BoundField>
        </Columns> 
        </asp:GridView>
    </div>



I have used a datatable as the grid source and bind to the grid in the Page_Load event

DataTable dtSource = new DataTable();

        #region Data Table Creation

        dtSource.Columns.Add("UserId");

        dtSource.Columns.Add("Name");

        dtSource.Columns.Add("Age");

        dtSource.Columns.Add("Address");

        dtSource.Columns.Add("Sex");

        dtSource.Columns.Add("DOB");

        dtSource.Columns.Add("Year");

        #endregion

        #region Add Rows
        dtSource.Rows.Add("1", "nil1", "23", "aaaayyyyy", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("2", "nil2", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("3", "nil3", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("4", "nil4", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("5", "nil5", "23", "aaaa9999", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("6", "nil6", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("7", "nil7", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("8", "nil8", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("9", "nil9", "23", "aaaa", "male", "29/12/3456", "2345");
        dtSource.Rows.Add("10", "nil10", "23", "aaaa", "male", "29/12/3456", "2345");
        #endregion

        gvDetail.DataSource = dtSource;
        gvDetail.DataBind();



Hope this helps
Smile | :)

Niladri Biswas

GeneralRe: Autoscroll DataGridview Control Pin
Christian Graus4-Jun-09 16:26
protectorChristian Graus4-Jun-09 16:26 
AnswerRe: Autoscroll DataGridview Control Pin
Christian Graus4-Jun-09 16:25
protectorChristian Graus4-Jun-09 16:25 
QuestionHow to copy sysDiagrams when copying a database Pin
fiaolle4-Jun-09 8:51
fiaolle4-Jun-09 8:51 
QuestionIs it possible to use VB control in C#? Pin
Seraph_summer4-Jun-09 8:49
Seraph_summer4-Jun-09 8:49 
AnswerRe: Is it possible to use VB control in C#? Pin
DaveyM694-Jun-09 8:53
professionalDaveyM694-Jun-09 8:53 
AnswerRe: Is it possible to use VB control in C#? Pin
0x3c04-Jun-09 9:36
0x3c04-Jun-09 9:36 
GeneralRe: Is it possible to use VB control in C#? Pin
Seraph_summer4-Jun-09 10:08
Seraph_summer4-Jun-09 10:08 
GeneralRe: Is it possible to use VB control in C#? Pin
Dave Kreskowiak4-Jun-09 10:16
mveDave Kreskowiak4-Jun-09 10:16 
GeneralRe: Is it possible to use VB control in C#? Pin
0x3c04-Jun-09 10:24
0x3c04-Jun-09 10:24 
GeneralRe: Is it possible to use VB control in C#? Pin
harold aptroot4-Jun-09 10:45
harold aptroot4-Jun-09 10:45 
GeneralRe: Is it possible to use VB control in C#? Pin
Seraph_summer4-Jun-09 10:27
Seraph_summer4-Jun-09 10:27 
GeneralRe: Is it possible to use VB control in C#? Pin
harold aptroot4-Jun-09 10:53
harold aptroot4-Jun-09 10:53 
GeneralRe: Is it possible to use VB control in C#? Pin
Dave Kreskowiak4-Jun-09 12:58
mveDave Kreskowiak4-Jun-09 12:58 
GeneralRe: Is it possible to use VB control in C#? Pin
Christian Graus4-Jun-09 13:43
protectorChristian Graus4-Jun-09 13:43 
GeneralRe: Is it possible to use VB control in C#? Pin
Rajesh R Subramanian4-Jun-09 19:38
professionalRajesh R Subramanian4-Jun-09 19:38 
AnswerRe: Is it possible to use VB control in C#? Pin
Christian Graus4-Jun-09 11:49
protectorChristian Graus4-Jun-09 11:49 
QuestionRajdeep.net Pin
EliottA4-Jun-09 8:46
EliottA4-Jun-09 8:46 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.