Author |
Topic  |
|
AceC
New Member

Cyprus
68 Posts |
Posted - 26 April 2003 : 09:48:14
|
A user reached 6000 posts, and I started getting ruintime errors as soon as any of his messages came up.
Subscript out of range [number: 5]
line 133 inc_func_members.asp
By decreasing his post count to 5000, the problem went away, but he is close to notching up 6000 again.
I beleive it's something to do with the bonus count in inc_func_members but I just can't get my head round it at the moment.
Rem -User has reached the number of posts set for level Five
Rem -Will get an additional star
Rem -when his/her posts go up by the number of posts set for level Five
if intRank = 5 then
intBonusRank = 0
intBonusPosts = clng(fM_POSTS - (cint(intRankLevel5)))
if intBonusPosts > 0 then intBonusRank = (intBonusPosts\(cint(intrankLevel5)))
intRank = intRank + intBonusRank
end if
line 133 comes in this Select Case:
Select case fM_LEVEL
Case "1"
Rem -No Star to Normal Members if their posts are less then First Level
if intRank = 0 then getStar_Level = strStar_Level : exit function
strNewRankColor = arrRankColors(intRank - 1)
if intRank <= intMaxStars then intMaxStars = intRank
Case "2"
strNewRankColor = strRankColorMod
intMaxStars = NewRank(strModStars, intRank, intMaxStars)
Case "3"
strNewRankColor = strRankColorAdmin
intMaxStars = NewRank(strAdminStars, intRank, intMaxStars)
Rem -Give An Extra Star to Super Admin
if fM_ID = intAdminMemberID then intMaxStars = intMaxStars + 1
Case else
getStar_Level = strStar_Level & "Error"
exit function
end select
Any ideas apart from continually increasing the max star level (was at 3000 now at 6000 and the users post count now at 6757)? |
And the hit's just keep on comin' |
Edited by - Roland on 26 April 2003 11:24:05 |
|
Nikkol
Forum Moderator
    
USA
6907 Posts |
|
AceC
New Member

Cyprus
68 Posts |
Posted - 26 April 2003 : 10:10:35
|
Sorry, I didn't realise that, if a mod could move it there, that'd be great |
And the hit's just keep on comin' |
 |
|
Roland
Advanced Member
    
Netherlands
9335 Posts |
Posted - 26 April 2003 : 11:24:28
|
quote: Originally posted by AceC
Sorry, I didn't realise that, if a mod could move it there, that'd be great
done  |
 |
|
AceC
New Member

Cyprus
68 Posts |
Posted - 26 April 2003 : 12:13:55
|
Cheers, but can anyone decipher this and come up with a fix? |
And the hit's just keep on comin' |
 |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 26 April 2003 : 12:19:36
|
Try this code. I made some changes, though I have yet to test it. Changes are highlighted in green(commented out) and red(modified).
Rem -User has reached the number of posts set for level Five
Rem -Will get an additional star
Rem -when his/her posts go up by the number of posts set for level Five
if intRank = 5 then
intBonusRank = 0
intBonusPosts = clng(fM_POSTS - (cint(intRankLevel5)))
if intBonusPosts > 0 then intBonusRank = (intBonusPosts\(cint(intrankLevel5)))
'intRank = intRank + intBonusRank
end if
line 133 comes in this Select Case:
Select case fM_LEVEL
Case "1"
Rem -No Star to Normal Members if their posts are less then First Level
if intRank = 0 then getStar_Level = strStar_Level : exit function
strNewRankColor = arrRankColors(intRank - 1)
if (intRank +intBonusRank) <= intMaxStars then intMaxStars = intRank +intBonusRank
Case "2"
strNewRankColor = strRankColorMod
intMaxStars = NewRank(strModStars, intRank +intBonusRank, intMaxStars)
Case "3"
strNewRankColor = strRankColorAdmin
intMaxStars = NewRank(strAdminStars, intRank +intBonusRank, intMaxStars)
Rem -Give An Extra Star to Super Admin
if fM_ID = intAdminMemberID then intMaxStars = intMaxStars + 1
Case else
getStar_Level = strStar_Level & "Error"
exit function
end select
|
 |
|
AceC
New Member

Cyprus
68 Posts |
Posted - 26 April 2003 : 12:29:27
|
Cheers, will try it in a mo |
And the hit's just keep on comin' |
 |
|
AceC
New Member

Cyprus
68 Posts |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 26 April 2003 : 18:04:50
|
You are welcome  |
 |
|
ErEf
New Member

Netherlands
74 Posts |
Posted - 11 May 2003 : 04:06:02
|
just one but 
getting to that amount of posts will get one an extra star. in my ranking a member can have max 5 stars. he'll reach that with 700 posts, so the error was at 1400 posts. that is fixed now. But now that member has 6 stars... I wanted to know what happens at 2100 (triple) posts... he got another extra star so 7 . I suspect it happens every time one has another 700 posts.
but that is always better than an error  |
If you think you can or you think you cannot, you are right. - Henry Ford |
Edited by - ErEf on 11 May 2003 04:08:10 |
 |
|
Nikkol
Forum Moderator
    
USA
6907 Posts |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 11 May 2003 : 07:49:32
|
quote: Originally posted by ErEf
just one but  ...I suspect it happens every time one has another 700 posts.
I did this Mod and as far I remember that is how it should be. |
 |
|
ErEf
New Member

Netherlands
74 Posts |
Posted - 12 May 2003 : 03:25:24
|
So when a member reaches 7000 posts he has allready 5 because he reached the max amount of posts requiered for the 5 stars (in my case of course) and another 9 extra, makes 14 in total, which is more than admins and mods can get.
Is it possible to get arround that? that the max stars is the max? |
If you think you can or you think you cannot, you are right. - Henry Ford |
 |
|
masterao
Senior Member
   
Sweden
1678 Posts |
Posted - 12 May 2003 : 06:58:37
|
ErEf, you don't add the forum standard max stars to the mod's max stars, the mod replaces the forum max stars. With your example, a member with 7000 posts will have 9 stars.
The mod works for all members, including moderators and admins. Furthermore, you can set so that admins and moderators (separately) have normal (based on post count), one star always, one star minimum, or maximum number of stars. |
Jan =========== FR Portal Forums | Active Users 4.0.20 Mod |
 |
|
ErEf
New Member

Netherlands
74 Posts |
Posted - 12 May 2003 : 18:12:58
|
GauravBhabu you were right 6 is the max amount of stars in use on my forum. So it quits at 6. I thought a member could not get more then 5 stars because there are just 5 member levels.
thanks all for the explanation |
If you think you can or you think you cannot, you are right. - Henry Ford |
 |
|
|
Topic  |
|