Re: [WebDNA] lists opinion

This WebDNA talk-list message is from

2009


It keeps the original formatting.
numero = 103833
interpreted = N
texte = Same here. [break] would be cool in all loops to cut down or eliminate wasted processing. -Dan Strong http://www.DanStrong.com Brian Fries wrote: > Since we're talking about adding [break] tags, I believe they should be > available in EVERY looping context - [founditems], [listwords], > [formvariables], [listfiles], [lineitems], etc. Currently if I'm in a > looping context and I've already found what I need, I have to set a > "done" flag and add logic to ignore further passes through the loop. > > Brian Fries > BrainScan Software > > > On Oct 18, 2009, at 5:41 PM, Terry Nair wrote: > >> Hi guys, >> >> For the record, I do use a lot of switch/case scenarios. Both in >> WebDNA as >> well as in ActionScript (Flash/Flex). Totally agree with Ken that there >> should be a 'break' statement in WebDNA, just as there is in ActionScript >> (AS). Having said that, I must also state that I have not encountered a >> situation where more than 1 match occurs. I just want the 'break' so that >> one can immediately escape from a long iteration of switch/case the >> instant >> a match is made. >> >> Cheers Terry Nair >> >> -----Original Message----- >> From: Kenneth Grome [mailto:kengrome@gmail.com] >> Sent: Monday, October 19, 2009 06:26 >> To: talk@webdna.us >> Subject: Re: [WebDNA] lists opinion >> >>>> Why not change switch/case so that it only displays the first >>>> matching case? It displays all matching cases right now, and that's >>>> why I have never used it -- because I want it to display only the >>>> first matching case just like similar functions in other languages. >>> >>> >>> IIRC, switch case in PHP matches any all cases after the first >>> matching case.. until/unless it hits a break; statement. >> >> So maybe all webdna needs is a break statement which it currently does >> not >> have. Actually it has one, but it only works for [loop] -- not for >> [switch]. >> >> Sincerely, >> Ken Grome >> >> >> --------------------------------------------------------- >> This message is sent to you because you are subscribed to >> the mailing list . >> To unsubscribe, E-mail to: >> archives: http://mail.webdna.us/list/talk@webdna.us >> old archives: http://dev.webdna.us/TalkListArchive/ >> Bug Reporting: >> http://forum.webdna.us/eucabb.html?page=topics&category=288 > > --------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > archives: http://mail.webdna.us/list/talk@webdna.us > old archives: http://dev.webdna.us/TalkListArchive/ > Bug Reporting: http://forum.webdna.us/eucabb.html?page=topics&category=288 > Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] lists opinion - [listwords] delimiter change (Govinda 2009)
  2. Re: [WebDNA] lists opinion (Donovan Brooke 2009)
  3. Re: [WebDNA] lists opinion (Govinda 2009)
  4. Re: [WebDNA] lists opinion (Dan Strong 2009)
  5. Re: [WebDNA] lists opinion (Brian Fries 2009)
  6. RE: [WebDNA] lists opinion ("Terry Nair" 2009)
  7. Re: [WebDNA] lists opinion ("Terry Wilson" 2009)
  8. Re: [WebDNA] lists opinion (Kenneth Grome 2009)
  9. Re: [WebDNA] lists opinion (Govinda 2009)
  10. Re: [WebDNA] lists opinion (Kenneth Grome 2009)
  11. Re: [WebDNA] lists opinion (Govinda 2009)
  12. Re: [WebDNA] lists opinion (Donovan Brooke 2009)
  13. Re: [WebDNA] lists opinion - [listwords] delimiter change (Brian Fries 2009)
  14. Re: [WebDNA] lists opinion - [listwords] delimiter change (Donovan Brooke 2009)
  15. Re: [WebDNA] lists opinion (Brian Fries 2009)
  16. Re: [WebDNA] lists opinion (Govinda 2009)
  17. [WebDNA] lists opinion (Donovan Brooke 2009)
Same here. [break] would be cool in all loops to cut down or eliminate wasted processing. -Dan Strong http://www.DanStrong.com Brian Fries wrote: > Since we're talking about adding [break] tags, I believe they should be > available in EVERY looping context - [founditems], [listwords], > [formvariables], [listfiles], [lineitems], etc. Currently if I'm in a > looping context and I've already found what I need, I have to set a > "done" flag and add logic to ignore further passes through the loop. > > Brian Fries > BrainScan Software > > > On Oct 18, 2009, at 5:41 PM, Terry Nair wrote: > >> Hi guys, >> >> For the record, I do use a lot of switch/case scenarios. Both in >> WebDNA as >> well as in ActionScript (Flash/Flex). Totally agree with Ken that there >> should be a 'break' statement in WebDNA, just as there is in ActionScript >> (AS). Having said that, I must also state that I have not encountered a >> situation where more than 1 match occurs. I just want the 'break' so that >> one can immediately escape from a long iteration of switch/case the >> instant >> a match is made. >> >> Cheers Terry Nair >> >> -----Original Message----- >> From: Kenneth Grome [mailto:kengrome@gmail.com] >> Sent: Monday, October 19, 2009 06:26 >> To: talk@webdna.us >> Subject: Re: [WebDNA] lists opinion >> >>>> Why not change switch/case so that it only displays the first >>>> matching case? It displays all matching cases right now, and that's >>>> why I have never used it -- because I want it to display only the >>>> first matching case just like similar functions in other languages. >>> >>> >>> IIRC, switch case in PHP matches any all cases after the first >>> matching case.. until/unless it hits a break; statement. >> >> So maybe all webdna needs is a break statement which it currently does >> not >> have. Actually it has one, but it only works for [loop] -- not for >> [switch]. >> >> Sincerely, >> Ken Grome >> >> >> --------------------------------------------------------- >> This message is sent to you because you are subscribed to >> the mailing list . >> To unsubscribe, E-mail to: >> archives: http://mail.webdna.us/list/talk@webdna.us >> old archives: http://dev.webdna.us/TalkListArchive/ >> Bug Reporting: >> http://forum.webdna.us/eucabb.html?page=topics&category=288 > > --------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > archives: http://mail.webdna.us/list/talk@webdna.us > old archives: http://dev.webdna.us/TalkListArchive/ > Bug Reporting: http://forum.webdna.us/eucabb.html?page=topics&category=288 > Dan Strong

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:

[WebDNA] Reserved variables (2009) [OT] HTML Table Cell Problem (2003) Explorer 3.0/ Access Denied! (1997) [format 40s]text[/format] doesn't work (1997) Html mails and Outlook Win 2000 (2001) docs for WebCatalog2 (1997) [format] problem (2001) RE: Automatic thumbnail images (1998) [append] and SSL (1997) Help!!!! (1997) WebCat2b14MacPlugIn - [include] doesn't hide the search string (1997) Pithy questions on webcommerce & siteedit (1997) Attn: Bug in GeneralStore example b15 (1997) Help! 'An unknown error occurred: EMailNotCreated' (1999) Postprocessing CCs (2000) RAM variables (1997) RE: protect tag on NT (1997) [QuantityPrice] Not working in WebCatNT 2.0.1??? (1997) When do we get to request new features? (1999) I am sorry for always being such an ass (2004)