473,396 Members | 1,933 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How to find the total row count of datagrid using column name in vb.net?

2
Protected Sub invokePagination(ByVal table As DataTable)
'CallPagination() As PagingControlDTO
If table.Rows.Count > 0 Then
Me.DataGridPaging1.Visible = True
Me.DataGridPaging2.Visible = True
PgCntrl.RecordCount = CType(table.Rows(0)(12), Int64)PgCntrl.CurrentPage = CInt(ViewState("CurrentPage"))
If PgCntrl.CurrentPage = 0 Then
PgCntrl.CurrentPage = 1
End If
PgCntrl.isPrevClicked = False
PgCntrl.isNextClicked = False
PgCntrl.DisplaySummary = True
Me.DataGridPaging1.CallPagination =PgCntrl
Me.DataGridPaging2.CallPagination = PgCntrl

End If
End Sub


The code which is underlined is to be replaced.
Instead of this I want to use column name to get the total count , since it contain the total count.

Column Name is "TOTALROWCOUNT"
Apr 27 '12 #1
1 3009
Sudhir
2
Please help in resolving this problem. Please help..




@Sudhir
Apr 27 '12 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: JIM.H. | last post by:
Hello, string colVal =((TextBox)e.Item.Cells.Controls).Text; this is how I reach column value in a grid: how can I reach with the column name? some value should be int, some date, how should I...
2
by: Baren | last post by:
Hi!, I am using the following CSS class for the DataGrid Head column wherein i am sorting the recrods. The style works fine.. By default it puts an underline for each header column. The underlin...
1
by: Manch | last post by:
I need to dynamically retrieve the column index of a Windows Forms datagrid column. To reference the column I used the following code ...
17
by: Mike Fellows | last post by:
im trying (unsucessfully) to add a checkbox column to my datagrid i basically have a datagrid that im populating from a dataset Me.DataGrid1.DataSource = ds.Tables(0) the datagrid then has 5...
1
by: nate axtell | last post by:
In VB .NET I load the contents of an Excel or comma seperated values file into a dataGrid (via a datatable). One of the columns has a comma in the name of the column. So for the comma separated...
1
by: Eran AMiel | last post by:
Hi I need to get selected column name or index when user select one on datagrid. -- Thank For The Help Eran
2
by: Thomas Beyerlein | last post by:
Hello, I am looking it for a way of getting the column name, from a datagrid when the user clicks on one of the cells. I can get the value and the row Number and column Number, but can not seem to...
2
by: gane | last post by:
Any ideas on how to assign value to a datagrid cell referencing the column name? I would like to assign a value to a datagrid item using the column name (from web.config file) instead of using...
3
by: rn5a | last post by:
A SqlDataReader is populated with the records from a SQL Server 2005 DB table. The records retrieved depends upon 2 conditions (the conditions depend on what a user selects in an ASPX page). If...
9
by: john20 | last post by:
Hi All, How can i find the total 'Count' of a particular character's occurance in a string. means i want to find the count of '<' in a string. can you please help to find that. Thanks
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.