Author |
Topic |
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 09:23:11
|
Wow seems to be the week for Poll Mod questions.
I have the Poll mod working okay but I notice that when I look at the poll results it shows 12 votes. As the forum admin I also have the option of looking at who voted. When I do this it only shows 10 peoples names. I have also looked in the database which also only shows 10 members. Is there a reason why these two numbers don't match?? |
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 10:07:09
|
Can guests vote?
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 11:57:03
|
Dam I must have left it completly open to anyone. Problem now is I get an error if I try to change to members only:
Microsoft VBScript runtime error '800a000d'
Type mismatch: 'cint'
/forum/post_info.asp, line 460
Is this the same problem with regard to changing all the Cint to Clng code? Can I do this with an active poll going? |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 11:57:31
|
Yes.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 12:10:55
|
Just changed the Cint in post_info.asp and now I get:
Microsoft VBScript runtime error '800a000d'
Type mismatch: 'cLng'
/forum/post_info.asp, line 460
What now |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 12:28:35
|
That means the variable being passed to the clng function isn't a numerical one. Use response.write immediately before that line to write the varible to screen and see what it gives you.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 12:36:26
|
This is what I get:
Microsoft VBScript compilation error '800a03ea'
Syntax error
/forum/post_info.asp, line 460
response.write ReDim txtAns(Clng(count)) |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 12:37:28
|
And what's contained in the count variable?
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 12:38:48
|
Which count variable - number of votes?
|
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 12:40:37
|
The count variable that's being passed to the clng function, place response.write count on the line above line 460.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 12:41:47
|
Here is what I get:
True
Microsoft VBScript runtime error '800a000d'
Type mismatch: 'cLng'
/forum/post_info.asp, line 488 |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 12:43:33
|
This is the mode piece:
' ######################### Poll Mod ######################## if Request.Form("poll") = "1" then response.write count = Request.Form("count") ReDim txtAns(Clng(count)) For i = 1 To Clng(count) if trim(Request.Form("answer" & CStr(i))) <> "" then txtAns(i) = chkString(Request.Form("answer" & CStr(i)),"SQLString") else txtAns(i) = "" end if Next end if ' ########################################################### |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 12:43:55
|
Whatever you've done, count is now a boolean with a value of "True", it needs to be numerical to pass it through to the clng function. Go back to the Poll Mod readme and double check all the changes you made. Also, make sure that any other mods or custom code you are using are not using a variable called count.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
Edited by - Shaggy on 26 May 2005 12:44:06 |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 14:04:27
|
wow that was a chore but yes you were right I had miss-copied a couple of edits in post.asp and topic.asp.
Once again I am very grateful for all your help. |
|
|
Shaggy
Support Moderator
Ireland
6780 Posts |
Posted - 26 May 2005 : 14:37:04
|
You're welcome Hope you're learning, now, to double check your changes whenever you encounter errors applying mods.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
|
|
SLiPStreaM
Starting Member
USA
46 Posts |
Posted - 26 May 2005 : 15:37:04
|
Yes and I also need to learn - something I should already know - not to implement too many changes at once and to make sure each one works before going onto the next. |
|
|
|
Topic |
|