Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ToggleDisplay function
Message
Information générale
Forum:
ASP.NET
Catégorie:
Client-side développement
Versions des environnements
OS:
Windows XP
Database:
MS SQL Server
Divers
Thread ID:
01302997
Message ID:
01303186
Vues:
13
This message has been marked as the solution to the initial question of the thread.
JavaScript has an arguments collection that receives all parameters passed to it:
function CheckArgs()
{
   for(var x=0; x<arguments.length; x++)
   {
      alert(arguments[x]);
   }
}
You can also have actual parameters but pass more than the parameter list. They'll all show up in the arguments array in client script.



+++ Rick ---

>Hi everybody,
>
>I'd like to write a ToggleDisplay JavaScript function. Currently I'm calling it as
>
>this.btnSaveProfile.Attributes["onclick"] = "ToggleDisplay('GridInfo','ProfileInfo');";
>
>There is no problem to write it as accepting 2 parameters. But how can I make it more generic to process any number of parameters and toggle the display?
>
>Thanks a lot in advance.
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform