Ask a Question related to ASP.NET Data Grid Control, Design and Development.
-
gerry #1
Going to a specific page?
My client would like a alphabetic lookup bar to allow navigation to a
specific page of a datagrid - the page which has the first occurance of
the "key" field that starts with the clicked on letter. For example, if
the user clicks on "E-H" the datagrid will present the page which
contains the first occurance of an item which starts with E, F, G or H.
The alpha lookup bar supplements the existing next page/previous page
links.
My approach - brute force - is to sort the dataset alphabetically, find
the first row that meets the lookup criteria, calculate the page index
based on the row #, and then set the Datagrid.currentPageIndex to the
calculated page index. Does this seem like a reasonable approach? Is
there an easier method?
gerry Guest
-
Trouble linking from web page to specific page in a PDF
I'm having trouble linking to specific pages within a pdf. I've tried using page #'s and creating destinations in the pdf (my destination is called... -
access to a specific web page
Hello, I am using Contribute CS3 and I am trying to assign a user access to just 1 page only. But for some reason Contribute give the user... -
Redirect to specific page
Is there a way to configure the User Authentication so that each login is taken to a specific page? So a visitor with the login name... -
SSL on specific page
I have recently set the setting 'Require secure channel(SSL)' inside my IIS on a specific page (just my logon page). I want that page to use SSL... -
how to add link to a specific page in a pdf?
I think (hope) this is a simple question - I have a one page pdf that serves as a table of contents for a separate, larger multi-page pdf. Can I... -
Mohamed Sharaf #2
RE: Going to a specific page?
Hi Gerry,
I think you can use another approach which could save you a lot of
server resources. This approach based on SQL statement that get you the
specific record set you want.
For example, if you are using the customers table in Northwind database.
The select statement would be
Select * from customers where ContactName like '[e-h]%'
Does it sound appropriate for your case?
Best regards,
Mohamed Sharaf
MEA Developer Support Center
ITWorx on behalf Microsoft EMEA GTSC
--------------------
| From: "gerry" <zsxd432@yahoo.com>
| Newsgroups: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
| Subject: Going to a specific page?
| Date: 26 Sep 2005 07:44:44 -0700
| Organization: [url]http://groups.google.com[/url]
| Lines: 14
| Message-ID: <1127745884.458752.41290@g44g2000cwa.googlegroups. com>
| NNTP-Posting-Host: 24.54.208.186
| Mime-Version: 1.0
| Content-Type: text/plain; charset="iso-8859-1"
| X-Trace: posting.google.com 1127745889 18670 127.0.0.1 (26 Sep 2005
14:44:49 GMT)
| X-Complaints-To: [email]groups-abuse@google.com[/email]
| NNTP-Posting-Date: Mon, 26 Sep 2005 14:44:49 +0000 (UTC)
| User-Agent: G2/0.2
| X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1;
.NET CLR 1.0.3705; .NET CLR 1.1.4322),gzip(gfe),gzip(gfe)
| Complaints-To: [email]groups-abuse@google.com[/email]
| Injection-Info: g44g2000cwa.googlegroups.com; posting-host=24.54.208.186;
| posting-account=lttQ5AwAAADmzfHluUSfdlzz7GIIb_wi
| Path:
TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfee d00.sul.t-online.de!t-onli
ne.de!border2.nntp.dca.giganews.com!nntp.giganews. com!postnews.google.com!g4
4g2000cwa.googlegroups.com!not-for-mail
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.datagridc ontrol:5635
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
|
| My client would like a alphabetic lookup bar to allow navigation to a
| specific page of a datagrid - the page which has the first occurance of
| the "key" field that starts with the clicked on letter. For example, if
| the user clicks on "E-H" the datagrid will present the page which
| contains the first occurance of an item which starts with E, F, G or H.
| The alpha lookup bar supplements the existing next page/previous page
| links.
|
| My approach - brute force - is to sort the dataset alphabetically, find
| the first row that meets the lookup criteria, calculate the page index
| based on the row #, and then set the Datagrid.currentPageIndex to the
| calculated page index. Does this seem like a reasonable approach? Is
| there an easier method?
|
|
Mohamed Sharaf Guest
-
gerry #3
Re: Going to a specific page?
Thanks Mohamed!
Your suggestion is ideal. Unfortunately, the application doesn't have a
rationale data access layer - SQL is interspersed with presentation
code and business logic. I've taken a approach which is a variant of
your suggestion - defining a rowfilter on the dataview prior to binding
to the grid. Performance is not an issue. There are only a few hundred
records in the DB with anticipated growth of 10-20 records per year.
As an aside I'm taking the dataview filter approach for expediancy. A
supposedly senior developer who was also PM on the project with no
oversight created a monstrosity of an app - he's now gone. Since we've
already screwed the client the few $s left are being applied to meeting
the clients specific requirements while fixing the unseen
application/coding errors on our $. The last and biggest hurdle is to
build stored procedures for the primary datagrid. When I build the
stored procedures I'll add an option to constrain the search by alpha
range.
gerry Guest



Reply With Quote

