Jeff P
|
| Posted: 02/27/2005, 10:39 PM |
|
I have two grids on a single page, each with a navigation control. The second grid contains a pair of photographs relevant to the text being displayed in the first grid. If there are more than two relevant photographs the navigator for the photo grid can be used to display the others.
Suppose page 1 of the text has 4 photos associated with it (i.e., two pages each with 2 photos). The user navigates to the second page of the photos, thereby showing photos 3 and 4. The user then uses the navigator on the text grid to move to page 2 of the text, so the photo grid changes to show the photos associated with that particular text page. However, there are only 2 photos associated with this text page, but the photo grid is still pointing to a non-existant page 2 because that is the parameter carried forwards from the earlier text page. Since there is only one page for this photo grid, nothing is displayed. The photo grid needs to be reset to display page 1 of the photos.
How do I reset the page on grid 2 when the user navigates to a new text page on grid 1? Just being able to reset the page number on the second grid to Page 1 would probably be OK here.
You can view setup at http://www.thegasco.org/ but be aware that I have restricted the number of photos associated with each text page to just two to avoid this problem until I can resolve it.
|
|
|
 |
mrachow
Posts: 509
|
| Posted: 02/28/2005, 12:05 AM |
|
The current navigated page is controlled by a GET parameter
<gridName>Page.
Maybe in event BeforeShow of your first grid you have to remove that parameter.
If you have a search form you possibly can use the property Remove Parameters for that.
_________________
Best regards,
Michael |
 |
 |
Jeff P
|
| Posted: 02/28/2005, 9:47 PM |
|
Thank you, Michael. I couldn't get that suggestion to work. Perhaps I don't understand the syntax for:
CCRemoveParam(QueryString, ParameterName)
I guess ParameterName in this case is Grid_ImagesPage (Grid_Images is the gridName in your example) but I'm not sure what the QueryString means or what its value should be.
I have a feeling that I should be using something like the BeforeShowRow custom code in the NavGrid example of the CCSExamplePack, but that example isn't quite the same as what I'm trying to do.
|
|
|
 |
Jeff P
|
| Posted: 02/28/2005, 9:47 PM |
|
Thank you, Michael. I couldn't get that suggestion to work. Perhaps I don't understand the syntax for:
CCRemoveParam(QueryString, ParameterName)
I guess ParameterName in this case is Grid_ImagesPage (Grid_Images is the gridName in your example) but I'm not sure what the QueryString means or what its value should be.
I have a feeling that I should be using something like the BeforeShowRow custom code in the NavGrid example of the CCSExamplePack, but that example isn't quite the same as what I'm trying to do.
|
|
|
 |
Jeff P
|
| Posted: 02/28/2005, 9:47 PM |
|
Thank you, Michael. I couldn't get that suggestion to work. Perhaps I don't understand the syntax for:
CCRemoveParam(QueryString, ParameterName)
I guess ParameterName in this case is Grid_ImagesPage (Grid_Images is the gridName in your example) but I'm not sure what the QueryString means or what its value should be.
I have a feeling that I should be using something like the BeforeShowRow custom code in the NavGrid example of the CCSExamplePack, but that example isn't quite the same as what I'm trying to do.
|
|
|
 |
Jeff P
|
| Posted: 02/28/2005, 9:48 PM |
|
Ouch. Sorry about that. The forum was giving an error message when on submission.
|
|
|
 |
Jeff P
|
| Posted: 02/28/2005, 9:49 PM |
|
Ouch. Sorry about that. The forum was giving an error message when on submission.
|
|
|
 |
mrachow
Posts: 509
|
| Posted: 03/01/2005, 1:48 AM |
|
So try
CCRemoveParam(Request.QueryString,"Grid_ImagesPage")
_________________
Best regards,
Michael |
 |
 |
|