You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/search/tutorial-csharp-paging.md
+4-20Lines changed: 4 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ In this tutorial, you learn how to:
22
22
23
23
To complete this tutorial, you need to:
24
24
25
-
Have the [C# Tutorial: Create your first app - Azure Search](tutorial-csharp-create-first-app.md) project up and running. This project can either be your own version, or install it from TBD-First-app
25
+
Have the [C# Tutorial: Create your first app - Azure Search](tutorial-csharp-create-first-app.md) project up and running. This project can either be your own version, or install it from GitHub: [Create first app](https://github.com/Azure-Samples/azure-search-dotnet-samples).
26
26
27
27
## Extend your app with numbered paging
28
28
@@ -34,16 +34,10 @@ The system will be flexible enough to allow the number of visible page numbers t
34
34
35
35
The system will treat the left-most and right-most page number buttons as special, meaning they will trigger changing the range of page numbers displayed. For example, if page numbers 8, 9, 10, 11 and 12 are displayed, and the user clicks on 8, then the range of page numbers displayed changes to 6, 7, 8, 9, and 10. And there is a similar shift to the right if they selected 12.
36
36
37
-
38
-
### Start with your first search app
39
-
40
-
1. If you created it yourself and have the project handy, start from there. Alternatively download the first app from here.
41
-
xxxx
42
-
43
-
2. Run the project to make sure it works.
44
-
45
37
### Add paging fields to the model
46
38
39
+
Have the basic search page solution open.
40
+
47
41
1. Open the SearchData.cs model file.
48
42
49
43
2. First add some global variables. In MVC global variables are declared in their own static class. **ResultsPerPage** sets the number of results per page. **MaxPageRange** determines the number of visible page numbers on the view. **PageRangeDelta** determines how many pages left or right the page range should be shifted, when the left-most or right-most page number is selected. Typically this latter number is around half of **MaxPageRange**. Add the following code into the namespace.
@@ -381,8 +375,6 @@ Now select **Start Without Debugging** (or press the F5 key).
381
375
382
376

383
377
384
-
385
-
386
378
Now save off this project and let's try an alternative to this form of paging.
387
379
388
380
## Extend your app with infinite scrolling
@@ -391,15 +383,7 @@ Infinite scrolling is triggered when a user scrolls a vertical scroll bar to the
391
383
392
384
The important point here is that the page being displayed is not replaced, but appended to with the new results. A user can always scroll back up to the first results of the search.
393
385
394
-
To implement infinite scrolling, let's start with the project before adding any of the page number scrolling elements.
395
-
396
-
### Start with your first search app
397
-
398
-
1. If you created it yourself and have the project handy, start from there. Alternatively download the first app from here.
399
-
400
-
TBD
401
-
402
-
2. Run the project to make sure it still works.
386
+
To implement infinite scrolling, let's start with the project before any of the page number scrolling elements were added. So, if you need to, make another copy of the basic search page from GitHub: [Create first app](https://github.com/Azure-Samples/azure-search-dotnet-samples).
Copy file name to clipboardExpand all lines: articles/search/tutorial-csharp-type-ahead-and-suggestions.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,7 @@ In this tutorial, you learn how to:
24
24
25
25
To complete this tutorial, you need to:
26
26
27
-
Have the [C# Tutorial: Search results pagination - Azure Search](tutorial-csharp-paging.md) project up and running. This can either be your own version, or install it from TBD-Paging-Numbers
27
+
Have the [C# Tutorial: Search results pagination - Azure Search](tutorial-csharp-paging.md) project up and running. This can either be your own version, that you completed in the previous tutorial, or install it from GitHub: [Create first app](https://github.com/Azure-Samples/azure-search-dotnet-samples).
0 commit comments