Snippet Type(s): Expansion
Abstract (from author):
A QueryString (as in GET parameter) Property with replaceables for type, property name, and GET parameter. More info: http://www2.john.rummellcc.com/2007/05/querystring-property-c-code-snippet.html
Description (from snippet):
Code snippet for creating QueryString (GET Parameter) Properties.
Code Block:
1
2 protected $type$ $name$ $end$
3 {
4 get
5 {
6 string s = Request["$parameter$"];
7 $type$ $parameter$;
8
9 if (s == null)
10 {
11 //TODO: set $parameter$ to default value ...
12 }
13
14 try
15 {
16 //TODO: cast s to $type$ ...
17 }
18 catch
19 {
20 //TODO: set $parameter$ to default value ...
21 }
22
23 return $parameter$;
24 }
25 }
26
Download Now!
Download the snippet file by clicking the download button below. You may customize the snippet shortcut prior to downloading below.