Forum: ASP Mar 4th, 2008 |
| Replies: 45 Views: 4,426 You will only have one connection, but multiple record sets.
Change this a bit to do a more sophisticated join:
SQL = "SELECT CL.organisation,... |
Forum: ASP Mar 4th, 2008 |
| Replies: 45 Views: 4,426 you would have to remove them, or use some very complex regex which would be extremely slow. Something would be like:
[a-Z|-] for each character. You would end up having to search every character,... |
Forum: ASP Mar 3rd, 2008 |
| Replies: 45 Views: 4,426 The period is a wild card. You would first need to replace the string that you are working with. replace all "-" for "." and then setup your regex. This way it will match: email and e-mail. However,... |
Forum: ASP Feb 27th, 2008 |
| Replies: 3 Views: 809 What you do is count the amount of votes for each, then do tests on it like:
if counts > 0 then
'This is your percentage:
counts = (counts/totalcounts)
'This is your image width:
... |
Forum: ASP Feb 26th, 2008 |
| Replies: 4 Views: 1,181 The reason why it is coming up this way is that varexp is set to this:
' %
check what varexp's value is and make sure you have NO quotes in there whatsoever, as well as % signs. |
Forum: ASP Feb 26th, 2008 |
| Replies: 2 Views: 1,208 This is ASP.NET, you're posting in CLassic ASP section. Try posting here:
http://www.daniweb.com/forums/forum18.html |
Forum: ASP Feb 22nd, 2008 |
| Replies: 10 Views: 2,207 Put the form as POST, otherwise your querystring will be overridden. Then for your form action put :
action="<%= Request.ServerVariables("SCRIPT_NAME") & "?" &... |
Forum: ASP Feb 22nd, 2008 |
| Replies: 10 Views: 2,207 Also, try adding hidden input fields. It should still send the value through querystring with the GET method. |
Forum: ASP Feb 22nd, 2008 |
| Replies: 10 Views: 2,207 I don't understand, please explain a little more.
By changing the mode to POST for the form, nothing will be put in the querystring. You can then check for the form to see if it was submitted by... |
Forum: ASP Feb 22nd, 2008 |
| Replies: 10 Views: 2,207 You're setting RegID out of the Do While Not RS.EOF, so therefore it is never being set, or it is being set to the first record only.
Move it down to within the do while not rs.eof.
SQL = "SELECT... |
Forum: ASP Feb 21st, 2008 |
| Replies: 15 Views: 2,721 Yes you are in the wrong forum. Head over to ASP.NET
Then do a search for "Login Membership" and you'll find what you need to. It's been discussed many times. |
Forum: ASP Feb 19th, 2008 |
| Replies: 15 Views: 2,721 That's not asp, isn't that asp.net? different language, completely. |
Forum: ASP Feb 18th, 2008 |
| Replies: 15 Views: 2,721 That's pretty much it. The only thing you have to worry about is case sensitivity. This depends on your server settings on which it is set to case-sensitive or case-insensitive. You should pull the... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Next time, remind me to look at the query first lol.
You're welcome. |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 You probably don't even need middlecategory. If you wish, you should do it this way:
SQL = "SELECT TC.topcategory, DISTINCT(MC.middlecategory) "&_
"FROM tbtopcategory TC, tbmiddlecategory MC,... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 NO NO, you have to keep GROUP BY clause in there, if you don't, your records won't go in the right places, and you'll have duplicate columns!
You just need to lose the DISTINCT. DISTINCT grabs... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Oh okay that's how you have it set. Yeah that is fine. Not highly recommended, but it works. Okay then try this query:
SQL = "SELECT TC.topcategory, MC.middlecategory "&_
"FROM tbtopcategory TC,... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Yes it's what your database is pulling, not how the code handles it. You need a database redesign/restructure to better relate the data.
If it requires you for two queries to grab the information,... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Your databases aren't connected correctly. Your topcategory and middlecategory should be connected like this:
TopCat
- TopCatID
- TopCatName
MiddleCat
- MiddleCatID
- TopCatID
-... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Oh brother, try this code and then I will tell you what's wrong.
If Not RS.EOF Then
Response.Write("<table width=""570"" border=""1"">")
Do While Not RS.EOF
Response.Write("<tr>")
i = 0... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 The lovely good ole days of Classic ASP.
No reason why something shouldn't work, but there's the error. |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 This one:
If Not RS.EOF Then
Response.Write("<table width=""570"" border=""1"">")
Do While Not RS.EOF
Response.Write("<tr>")
i = 0
TopCat = RS("topcategory")
MiddleCat =... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Not the code on this page, the code on page 6, the second to last code I sent you. |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 I don't know then. It should all work just fine, especially with the 2nd to last code I gave you. I mean, it looped through all the top cats, caught the middles, then went on. Now nothing at all? |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 wait, you didn't declare the variable before? Run the last code where you said it looks good.
The reason why it kept skipping over is that it didn't keep LastTopCat in memory, therefore when it... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Let's loose all the stupid loops.
Oh please tell me you "Dim LastTopCat" at the top of the page right?
Try this:
If Not RS.EOF Then
Response.Write("<table width=""570"" border=""1"">")... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 I edited it, it was mistake of placement of I, retry it with new code. |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Ok, try this:
If Not RS.EOF Then
Response.Write("<table width=""570"" border=""1"">")
Do While Not RS.EOF
Response.Write("<tr>")
i = 0
TopCat = RS("topcategory")
MiddleCat =... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 How many middles are there for each one. You have 7 cats, look in your DB for the middles in each one so I have the number. Then I can trully know what I am looking at. |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 work with me here.. the code I gave you had "MiddleCat" and "MiddelCat", which is why MiddleCat is repeating, since it is never being reset.
Just make that change, MiddelCat --> MiddleCat
Same... |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 Show me the screenshot, so I am not guessing in the dark please :) |
Forum: ASP Feb 15th, 2008 |
| Replies: 88 Views: 7,051 With your original SQL, try the below code:
If Not RS.EOF Then
Response.Write("<table width=""570"" border=""1"">")
Do While Not RS.EOF
Response.Write("<tr>")
i = 0
TopCat =... |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 Last chance. It should work also, just like the rest right? lol
If Not rs.EOF Then
Response.Write("<table width=""570"" border=""1"">")
Do Until RS.EOF
Response.Write("<tr>")
i =... |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 Change the DoWhile ending from Loop to End While. I am working on an alternate real quick, then I gotta go as its VDay. |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 Oh yeah forgot to check for EOF on that portion. Here you go:
If Not RS.EOF then
Response.Write("<table width=""570"" border=""1"">")
Do Until RS.EOF
Response.Write("<tr>")
For... |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 Ok it will, but you have to add this line after
RS.MoveNext
TopCat = RS("topcategory")
You need a second one there in order to reset the topcat. Keep both. Just add that line after... |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 That won't work either. Hold on, let me put everything else aside for a minute. |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 lmao. Doing 4 different tasks is a bit much for me I guess. Of course that won't work lol.
Try this:
If Not RS.EOF then
Response.Write("<table width=""570"" border=""1"">")
Do Until... |
Forum: ASP Feb 14th, 2008 |
| Replies: 88 Views: 7,051 hey, want to know why it errors? lol
It is never finding an end. There's a mistake in the code, and it's where it says "cols"
Remove cols, and have just "3".
For i=1 to 3
And it wont... |