Re: [ShowIf] if the varieable exists

This WebDNA talk-list message is from

1998


It keeps the original formatting.
numero = 20292
interpreted = N
texte = On 10/8/98 10:23 AM Mike Eberly wrote >I understand that normally you would put the [ShowIf] context followed >by the equation. >ex: [ShowIf [wogroup1datarq]=Mustang]Car[/ShowIf] >However, there will not always be an existing variable called >[wogroup1datarq]. Instead, I would like to [ShowIf] if the variable >[wogroup1datarq] exists. How can I do this?I just got done doing this. It was a blast on top of it I had added complications. Here is the code I created. Basically I used the formvariable tag to extract the information I wanted. What a hoot, Do that with asp![formvariables] [math show=f]num2=[index][/math] [showif [num2]=[num1]] [text show=f]rt[num3]=[value][/text] [/showif] [showif [name]^state] [math show=f]num1=[index]+1[/math] [math show=f]num3=num3+1[/math] [text show=f]st[num3]=[value][/text] [/showif] [/formvariables]basically I asked if to show any formvariables that contain the word state, then I needed the very next formvariable so I created a routine to grab it as well. of course all the math [num*] variable were initial set to zero.The page prior was submitting a series of checkboxes associated with text boxes and I didn't want to write a [showif] for every possiblity additionall the check boxes are created with a database so the number of fields itself could vary. enjoy :) Robert Minor _________________________________________________________________________ Cybermill Communications webmaster@cybermill.com 8616 Joseph Ave. http://www.cybermill.com St. Louis, MO 63144 (314) 962-4024 _________________________________________________________________________ Purveyors of fine websites and high bandwith. Colocation and domain hosting available. Associated Messages, from the most recent to the oldest:

    
  1. Re: [ShowIf] if the varieable exists (Grant Hulbert 1998)
  2. Re: [ShowIf] if the varieable exists (Scott Szretter 1998)
  3. Re: [ShowIf] if the varieable exists (Howard Wolosky 1998)
  4. Re: [ShowIf] if the varieable exists (Howard Wolosky 1998)
  5. Re: [ShowIf] if the varieable exists (Howard Wolosky 1998)
  6. Re: [ShowIf] if the varieable exists (bob 1998)
  7. Re: [ShowIf] if the varieable exists (Howard Wolosky 1998)
  8. Re: [ShowIf] if the varieable exists (Christer Olsson 1998)
  9. Re: [ShowIf] if the varieable exists (PCS Technical Support 1998)
  10. [ShowIf] if the varieable exists (Mike Eberly 1998)
On 10/8/98 10:23 AM Mike Eberly wrote >I understand that normally you would put the [showif] context followed >by the equation. >ex: [ShowIf [wogroup1datarq]=Mustang]Car[/ShowIf] >However, there will not always be an existing variable called >[wogroup1datarq]. Instead, I would like to [showif] if the variable >[wogroup1datarq] exists. How can I do this?I just got done doing this. It was a blast on top of it I had added complications. Here is the code I created. Basically I used the formvariable tag to extract the information I wanted. What a hoot, Do that with asp![formvariables] [math show=f]num2=[index][/math] [showif [num2]=[num1]] [text show=f]rt[num3]=[value][/text] [/showif] [showif [name]^state] [math show=f]num1=[index]+1[/math] [math show=f]num3=num3+1[/math] [text show=f]st[num3]=[value][/text] [/showif] [/formvariables]basically I asked if to show any formvariables that contain the word state, then I needed the very next formvariable so I created a routine to grab it as well. of course all the math [num*] variable were initial set to zero.The page prior was submitting a series of checkboxes associated with text boxes and I didn't want to write a [showif] for every possiblity additionall the check boxes are created with a database so the number of fields itself could vary. enjoy :) Robert Minor _________________________________________________________________________ Cybermill Communications webmaster@cybermill.com 8616 Joseph Ave. http://www.cybermill.com St. Louis, MO 63144 (314) 962-4024 _________________________________________________________________________ Purveyors of fine websites and high bandwith. Colocation and domain hosting available. bob

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:

WebCommerce: Folder organization ? (1997) system crashes, event log (1997) Referrer field to header field conversion (1997) [include ...] behavior (1997) Running _every_ page through WebCat ? (1997) Great product and great job ! (1997) [isfile] ? (1997) New NT beta available (1997) help needed: Non-english characters in WebCatalog (1997) Some pointers please (2008) Newbie Tax Question (1997) Server Freeze (1998) When is unitShipCost calculated? (1998) WebCat2b12 - nesting [tags] (1997) Keeping track of revision history, etc. (2005) To Use Cookies or Not To Use Cookies (2003) [WebDNA] WebDNA Crashing or Not **YES** (2008) Page-Execution-Timer...PHP vs WebDNA (2004) [FoundItems] solved - thanks (1997) Locking up with WebCatalog... (1997)