Re: Loop code problem

This WebDNA talk-list message is from

2000


It keeps the original formatting.
numero = 30048
interpreted = N
texte = > Can anyone tell me what is wrong with the following code? This is intended to > update all ten rows of a small database. The fields __CNAME and __PCT have > been set up via a form on the same page. > > [Math show=f]LOOPNUM=0[/Math] > [loop start=1&end=10] > [Math show=f] LOOPNUM=([LOOPNUM]+1) [/Math] > [replace > db=holdings.db&eqCNUM=[LOOPNUM]]CNAME=[__CNAME[LOOPNUM]]&PCT=[__PCT[LOOPNUM]][ > /replace] > [/loop]Take the spaces out of your [math] context.If you want to know what is wrong in your repalce, just take the first [ out of the [replace] tag, plus delete the [/replace] tag. Then you'll see if it looks ok.Very common debugging technique. ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Associated Messages, from the most recent to the oldest:

    
  1. Re: Loop code problem (Anup setty 2000)
  2. Re: Loop code problem (WebDNA Support 2000)
  3. Loop code problem (Ralph Dratman 2000)
  4. Re: Loop code problem (Kenneth Grome 2000)
  5. Re: Loop code problem (Kenneth Grome 2000)
  6. Re: Loop code problem (Anup setty 2000)
  7. Re: Loop code problem (Jason Sofonia 2000)
  8. Re: Loop code problem (Anup setty 2000)
  9. Re: Loop code problem (Nicolas Verhaeghe 2000)
  10. Re: Loop code problem (Nicolas Verhaeghe 2000)
  11. Re: Loop code problem (Anup setty 2000)
  12. Loop code problem (Ralph Dratman 2000)
> Can anyone tell me what is wrong with the following code? This is intended to > update all ten rows of a small database. The fields __CNAME and __PCT have > been set up via a form on the same page. > > [Math show=f]LOOPNUM=0[/Math] > [loop start=1&end=10] > [Math show=f] LOOPNUM=([LOOPNUM]+1) [/Math] > [replace > db=holdings.db&eqCNUM=[LOOPNUM]]CNAME=[__CNAME[LOOPNUM]]&PCT=[__PCT[LOOPNUM]][ > /replace] > [/loop]Take the spaces out of your [math] context.If you want to know what is wrong in your repalce, just take the first [ out of the [replace] tag, plus delete the [/replace] tag. Then you'll see if it looks ok.Very common debugging technique. ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Nicolas Verhaeghe

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

For those of you not on the WebCatalog Beta... (1997) Nested Loops and SHOWIFs (1997) emailer (1997) How can I Add several Items into the cart at once? (1997) [WebDNA] 6.2 Monitor (2012) ShowIf & HideIf Question? (1998) More on the email templates (1997) Our Webcat site launched (1997) Cancel Subscription (1996) [isfile] ? (1997) WebCat2b13MacPlugIn - [shownext method=post] ??? (1997) WebMerchant and PCAuthorize (1998) Https not showing products (2004) Triggers (2003) [shell] (2002) Configuring E-mail (1997) customer.db and forms (1999) Re1000001: Setting up shop (1997) Share cost of training videos! (1998) No Answer on Web Merchant Problem? (2001)