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 Stronghttp://www.DanStrong.comBrian 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:
Same here. [break] would be cool in all loops to cut down or eliminate wasted processing.-Dan Stronghttp://www.DanStrong.comBrian 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:
WebCatalog Mac 2.1b3 (1997)
[WebDNA] WebDNA Crashing or Not **YES** (2008)
[Sum] function? (1997)
bulletin board spell check (2001)
summ=T (2003)
Here we go again... (2006)
[WebDNA] Brian Harrington (2019)
Math function in Formula.db (1997)
Secured Order Forms (1998)
Byte Order Mark - removing via webcat? (2006)
[ModDate] & [ModTime] ? (1997)
Spaces in sendmail (1998)
GuestBook example (1997)
RE: How to verify email address (1997)
verify online (1997)
Setting up WebCatalog with Retail Pro data (1996)
WebCatalog2 Feature Feedback (1996)
Migrating to NT (1997)
Format question WC Mac f3 (1997)
BUG in [showif] using ^ (contains) (1997)