rickwp Posts:20
 |
| 01/08/2008 4:13 AM |
|
When I insert {Pager}{Pager:RecordsPerPage}5{/Pager:RecordsPerPage}{/Pager}Page {Pager:CurrentPage} of {Pager:PageCount} into the header, template, or footer (tried it in each area separately) in the module settings it gives this error: A critical error has occurred. Argument 'Length' must be greater or equal to zero. If I remove the {Pager} code, it works fine. If the page only has 5 or fewer records, the Page 1 of 1 works fine. It seems to be just the {Pager}{Pager:RecordsPerPage}5{/Pager:RecordsPerPage}{/Pager} that is causing the problem. What am I doing wrong? Rick |
|
|
|
|
host Posts:93
 |
| 01/08/2008 7:24 AM |
|
This is the pager tag from our bugtracker module {Pager}{Pager:RecordsPerPage}5{/Pager:RecordsPerPage}{/Pager} Page {Pager:CurrentPage} of {Pager:PageCount} A critical error has occurred. Argument 'Length' must be greater or equal to zero. Usually means the tags are not well formed. |
|
|
|
|
rickwp Posts:20
 |
| 01/08/2008 7:54 AM |
|
| Ok. But, what is not well formed about them? I'm using them as instructed in the manual, and tried placing this in the header, the footer, the template, inside the template/end template comment tags. I have no idea what is wrong. If it were other tags causing the problem, then wouldn't a problem persist when all the pager tags are removed? I don't get it. The man in charge was going to have 26,000 records get listed on one page and I talked him into using the pager feature. Now, I wish I hadn't if it won't work. |
|
|
|
|
host Posts:93
 |
| 01/08/2008 8:01 AM |
|
| Copy and paste the code above into the footer of your module and tell me what happens. I just tried it on a brand new built and installed module and it works fine for me. |
|
|
|
|
rickwp Posts:20
 |
| 01/08/2008 3:52 PM |
|
I did a cut/paste of the text above from your post and it gives the same error. I also removed the line break so the code flows as one line, and got the same error. This error also occurred on a new module built from scratch, after uninstalling the old module from DNN to remove all the old files and database table first before installing the new module. Do you want me to send the module PA or export the module from within Module Builder? Also, I'm using Module Builder 4.5.12. Rick |
|
|
|
|
rickwp Posts:20
 |
| 01/08/2008 3:53 PM |
|
Also, this is a DNN 4.6.2 install. The client uses Catalook.net Store, so the DNN version has to match Catalook version exactly. Rick |
|
|
|
|
rickwp Posts:20
 |
| 01/08/2008 4:03 PM |
|
Also, In Visual Web Developer Express 2005, the code gives this error in ViewArticles.ascx.vb for "Protected Function BuildPager": Variable BuildPager is used before it has been assigned a value. A null reference exception could result at runtime. This is the section of code: If intPageCount > 1 Then For i = 1 To intPageCount Step 1 If curpage <> i Then BuildPager = BuildPager & "" & i & "" & " " Else BuildPager = BuildPager & "" & i & "" & " " End If Next i Else BuildPager = "" End If Could this be the reason? That it may actually be the null reference exception this error refers to? Rick |
|
|
|
|
rickwp Posts:20
 |
| 01/08/2008 4:05 PM |
|
| Well, the forum module removed a bunch of the html tags in the code that I pasted above... |
|
|
|
|
host Posts:93
 |
| 01/08/2008 4:22 PM |
|
| Can you send the module zip file to support@socani.org. We'll get them to look at it. |
|
|
|
|
rickwp Posts:20
 |
| 01/08/2008 8:31 PM |
|
Sure. I sent the module PA and also exported the module and sent that also. Thanks, Rick |
|
|
|
|