Is the datagrid control sort and paging commands work only when both the
page and grid property EnableViuewState=True ?
when i tryed running the page when either one of them was set to false the
sorting or paging didn't work. i just got an black page and the commands
methods was not called.
I really wish i can work with the grid without the viewstate, performance
best practices recommend not to use view state.
TIA, z. 7 1133
you just need to manually map in the page load if viewstate is set to false
datagrid1.sortcommand += point to the sort command handler routine
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:uR**************@TK2MSFTNGP09.phx.gbl... Is the datagrid control sort and paging commands work only when both the page and grid property EnableViuewState=True ?
when i tryed running the page when either one of them was set to false the sorting or paging didn't work. i just got an black page and the commands methods was not called.
I really wish i can work with the grid without the viewstate, performance best practices recommend not to use view state.
TIA, z.
sorry for not understanding but, this is VB and the handler looks like
function ....... handles datagrid1.OnSortCommand (might be a little
different)
and in the V code there is no additions to the objects event handler like in
C#, so should i do it also in VB?
"Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message
news:O5**************@TK2MSFTNGP10.phx.gbl... you just need to manually map in the page load if viewstate is set to
false datagrid1.sortcommand += point to the sort command handler routine
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message news:uR**************@TK2MSFTNGP09.phx.gbl... Is the datagrid control sort and paging commands work only when both the page and grid property EnableViuewState=True ?
when i tryed running the page when either one of them was set to false
the sorting or paging didn't work. i just got an black page and the commands methods was not called.
I really wish i can work with the grid without the viewstate,
performance best practices recommend not to use view state.
TIA, z.
ya vb does it differently. you will need a vb person in here to help with
the code
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
"z f" <zi**@info-scope.co.il> wrote in message
news:eh**************@TK2MSFTNGP12.phx.gbl... sorry for not understanding but, this is VB and the handler looks like function ....... handles datagrid1.OnSortCommand (might be a little different)
and in the V code there is no additions to the objects event handler like in C#, so should i do it also in VB? "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message news:O5**************@TK2MSFTNGP10.phx.gbl... you just need to manually map in the page load if viewstate is set to false datagrid1.sortcommand += point to the sort command handler routine
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message news:uR**************@TK2MSFTNGP09.phx.gbl... > Is the datagrid control sort and paging commands work only when both > the > page and grid property EnableViuewState=True ? > > when i tryed running the page when either one of them was set to false the > sorting or paging didn't work. i just got an black page and the > commands > methods was not called. > > I really wish i can work with the grid without the viewstate, performance > best practices recommend not to use view state. > > > TIA, z. > >
so must i have the EnableViewState=True in order to receive the grid events?
"Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl... ya vb does it differently. you will need a vb person in here to help with the code
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z f" <zi**@info-scope.co.il> wrote in message news:eh**************@TK2MSFTNGP12.phx.gbl... sorry for not understanding but, this is VB and the handler looks like function ....... handles datagrid1.OnSortCommand (might be a little different)
and in the V code there is no additions to the objects event handler
like in C#, so should i do it also in VB? "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message news:O5**************@TK2MSFTNGP10.phx.gbl... you just need to manually map in the page load if viewstate is set to false datagrid1.sortcommand += point to the sort command handler routine
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message news:uR**************@TK2MSFTNGP09.phx.gbl... > Is the datagrid control sort and paging commands work only when both > the > page and grid property EnableViuewState=True ? > > when i tryed running the page when either one of them was set to
false the > sorting or paging didn't work. i just got an black page and the > commands > methods was not called. > > I really wish i can work with the grid without the viewstate, performance > best practices recommend not to use view state. > > > TIA, z. > >
no it should be false, which is why you have to manually rebind it in the
page_load event each time.
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
"z f" <zi**@info-scope.co.il> wrote in message
news:eQ**************@tk2msftngp13.phx.gbl... so must i have the EnableViewState=True in order to receive the grid events?
"Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message news:%2****************@TK2MSFTNGP10.phx.gbl... ya vb does it differently. you will need a vb person in here to help with the code
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z f" <zi**@info-scope.co.il> wrote in message news:eh**************@TK2MSFTNGP12.phx.gbl... > sorry for not understanding but, this is VB and the handler looks like > function ....... handles datagrid1.OnSortCommand (might be a little > different) > > and in the V code there is no additions to the objects event handler like > in > C#, so should i do it also in VB? > > > > "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message > news:O5**************@TK2MSFTNGP10.phx.gbl... >> you just need to manually map in the page load if viewstate is set to > false >> datagrid1.sortcommand += point to the sort command handler routine >> >> -- >> Regards, >> Alvin Bruney >> [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] >> Got tidbits? Get it here... http://tinyurl.com/27cok >> "z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message >> news:uR**************@TK2MSFTNGP09.phx.gbl... >> > Is the datagrid control sort and paging commands work only when both >> > the >> > page and grid property EnableViuewState=True ? >> > >> > when i tryed running the page when either one of them was set to false > the >> > sorting or paging didn't work. i just got an black page and the >> > commands >> > methods was not called. >> > >> > I really wish i can work with the grid without the viewstate, > performance >> > best practices recommend not to use view state. >> > >> > >> > TIA, z. >> > >> > >> >> > >
is should manually rebind it in the page_load event and not from the
InitializeComponent that is called from the OnInit method?
"Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message
news:uw**************@TK2MSFTNGP09.phx.gbl... no it should be false, which is why you have to manually rebind it in the page_load event each time.
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z f" <zi**@info-scope.co.il> wrote in message news:eQ**************@tk2msftngp13.phx.gbl... so must i have the EnableViewState=True in order to receive the grid events?
"Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message news:%2****************@TK2MSFTNGP10.phx.gbl... ya vb does it differently. you will need a vb person in here to help
with the code
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z f" <zi**@info-scope.co.il> wrote in message news:eh**************@TK2MSFTNGP12.phx.gbl... > sorry for not understanding but, this is VB and the handler looks
like > function ....... handles datagrid1.OnSortCommand (might be a little > different) > > and in the V code there is no additions to the objects event handler like > in > C#, so should i do it also in VB? > > > > "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message > news:O5**************@TK2MSFTNGP10.phx.gbl... >> you just need to manually map in the page load if viewstate is set
to > false >> datagrid1.sortcommand += point to the sort command handler routine >> >> -- >> Regards, >> Alvin Bruney >> [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] >> Got tidbits? Get it here... http://tinyurl.com/27cok >> "z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message >> news:uR**************@TK2MSFTNGP09.phx.gbl... >> > Is the datagrid control sort and paging commands work only when
both >> > the >> > page and grid property EnableViuewState=True ? >> > >> > when i tryed running the page when either one of them was set to false > the >> > sorting or paging didn't work. i just got an black page and the >> > commands >> > methods was not called. >> > >> > I really wish i can work with the grid without the viewstate, > performance >> > best practices recommend not to use view state. >> > >> > >> > TIA, z. >> > >> > >> >> > >
right
page_load
{
if(!page.ispostback)
{
}
//rebind grid here
}
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
"z f" <zi**@info-scope.co.il> wrote in message
news:u$*************@tk2msftngp13.phx.gbl... is should manually rebind it in the page_load event and not from the InitializeComponent that is called from the OnInit method? "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message news:uw**************@TK2MSFTNGP09.phx.gbl... no it should be false, which is why you have to manually rebind it in the page_load event each time.
-- Regards, Alvin Bruney [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] Got tidbits? Get it here... http://tinyurl.com/27cok "z f" <zi**@info-scope.co.il> wrote in message news:eQ**************@tk2msftngp13.phx.gbl... > so must i have the EnableViewState=True in order to receive the grid > events? > > > > > "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in message > news:%2****************@TK2MSFTNGP10.phx.gbl... >> ya vb does it differently. you will need a vb person in here to help with >> the code >> >> -- >> Regards, >> Alvin Bruney >> [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] >> Got tidbits? Get it here... http://tinyurl.com/27cok >> "z f" <zi**@info-scope.co.il> wrote in message >> news:eh**************@TK2MSFTNGP12.phx.gbl... >> > sorry for not understanding but, this is VB and the handler looks like >> > function ....... handles datagrid1.OnSortCommand (might be a little >> > different) >> > >> > and in the V code there is no additions to the objects event handler > like >> > in >> > C#, so should i do it also in VB? >> > >> > >> > >> > "Alvin Bruney [MVP]" <vapor at steaming post office> wrote in >> > message >> > news:O5**************@TK2MSFTNGP10.phx.gbl... >> >> you just need to manually map in the page load if viewstate is set to >> > false >> >> datagrid1.sortcommand += point to the sort command handler routine >> >> >> >> -- >> >> Regards, >> >> Alvin Bruney >> >> [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx] >> >> Got tidbits? Get it here... http://tinyurl.com/27cok >> >> "z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message >> >> news:uR**************@TK2MSFTNGP09.phx.gbl... >> >> > Is the datagrid control sort and paging commands work only when both >> >> > the >> >> > page and grid property EnableViuewState=True ? >> >> > >> >> > when i tryed running the page when either one of them was set to > false >> > the >> >> > sorting or paging didn't work. i just got an black page and the >> >> > commands >> >> > methods was not called. >> >> > >> >> > I really wish i can work with the grid without the viewstate, >> > performance >> >> > best practices recommend not to use view state. >> >> > >> >> > >> >> > TIA, z. >> >> > >> >> > >> >> >> >> >> > >> > >> >> > >
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Jeff |
last post by:
IDE: VS 2003 :NET
OS: XP Pro
My app have a form with a tab-control on it. The tab-control have 2
tabpages. One of the tabpages displays a datagrid, and the other tabpage
displays details (order...
|
by: Carolyn Vo |
last post by:
I have been looking and looking but can't seem to find out how to get the row
selected in a web control datagrid (NOT a web form datagrid!!!), and how to
highlight the selected row. I'm sure this...
|
by: Ryan Liu |
last post by:
Hi there,
I got a NullReferenceException when delete last row in a datagrid.
I had hard time to solve since it does not occur in my own code.
I put a datagrid in my inherited user control,...
|
by: Dominic |
last post by:
Hi guys,
I'm not sure if this question belongs to FAQ, but I couldn't find a
concrete answer.
I created a Datagrid control using ItemTemplate, but it's NOT a
in-place editing datagrid. One of...
|
by: Glenn Owens |
last post by:
I have a DataGrid web control which I've dynamically populated with
template columns to be used for bulk-editting. Generally, all of the
columns are textbox and/or dropdownlist child controls.
...
|
by: Jim Heavey |
last post by:
Trying to figure out the technique which should be used
to add rows to a datagrid. I am thinking that I would
want an "Add" button on the footer, but I am not quite
sure how to do that. Is that...
|
by: Craig Banks |
last post by:
If a row of data in a dataset has a lot of columns the row displaying the
data in a datagrid will run way off the screen. What I'd like to do is
display a row of data over several datagrid rows so...
|
by: thegame |
last post by:
Filling One DataGrid Based on Selection from Another DataGrid - Both in
Separate User Controls
Hello, I have an interesting dilemma.
I have an ASPX page with two user controls (two ASCXs). ...
|
by: pmcguire |
last post by:
I have a DataGrid control for which I have also created several new extended
DataGridColumnStyles. They behave pretty nicely, but I can't figure out how
to implement Selected Item formatting for...
|
by: chreo |
last post by:
Hello.
I have datagrid.
I found code to select all row in data grid (by mouse or arrow keys).
This works great - user can select row and...
....and I want to go to next control.
For...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
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...
|
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
|
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...
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
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...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
| |