Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Classic ASP Professional For advanced coder questions in ASP 3. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Professional section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old July 25th, 2006, 12:11 AM
Friend of Wrox
 
Join Date: May 2005
Location: tehran, tehran, Iran.
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default nested for

Hello all
I need 2 nested for that compare each i with each a(j) and if that i wasn't in a() array write that i.I wrote the code below but it repeats each record 14 times:(14 is half of i(s).the total i quantitties are 28)
for i=23 to 50
   For j=0 to Ubound(a)
       if a(j)=i then
           j=Ubound(a)
       else
           if j=Ubound(a) then
              response.write(i)
           end if
      end if
   next
next
would you please tell me where is the problem?
thank you

Reply With Quote
  #2 (permalink)  
Old July 27th, 2006, 06:28 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Ok i am having a hard time understanding what you are trying to accomplish. I understand that you are executing the outer loop 28 times which will fire the inner for loop 28 times and the inner for will loop for X number of times.

But what do you mean it repeast each record 14 times??

"The one language all programmers understand is profanity."
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nested query deb1980 ASP.NET 2.0 Basics 2 April 10th, 2007 04:38 AM
nested for-each sassymonix XSLT 6 May 16th, 2006 06:47 AM
Nested If Statement KCTin Visual Basic 2005 Basics 3 December 28th, 2005 01:53 PM
Nested If pans Access 4 December 10th, 2004 12:39 AM
Nested Do Until Loop goels Access VBA 2 September 30th, 2004 08:44 AM



All times are GMT -4. The time now is 01:41 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.