ASP.NET - odeslání formáře klávesou Enter

Problém

Uživatel reklamuje, že nelze formulář odesílát tlačítkem Enter, ale pouze kliknutím na button.

Řešení

Dá se to řešit JavaScriptem, ale to nefunguje stejně ve všech prohlížečích. Zde je řešení, které se osvědčilo. Stačí formulářové prvky obalit prvkem Panel a nastavit atribut DefaultButton.

<asp:Panel ID="Panel1" runat="server" DefaultButton="btnSubmit">
    <div>
        <asp:TextBox ID="txtUserID" runat="server"/>
        <asp:TextBox ID="txtUserpwd" runat="server"/>
        <asp:Button ID="btnSubmit" runat="server" OnClick="btnSubmit _Click" Text="Submit"/>
    </div>
</asp:Panel > 

Online nástroje I.

Windows PowerShell for SharePoint Command Builder

Online tvorba PowerShell příkazů, včetně referencí do návodů k příkazům.
Microsoft.com

Photoshop Online Tools

Online úprava fotografií.
Photoshop.com

PDF Converter

Převod souborů mezi formáty - PDF, Word, Excel, PowerPoint, obrázek.
FreePdfConvert.com

Browser Shots

Provede kontrolu zobrazování html stránky v předem definovaných prohlížečích a výsledek vrátí jako obrázky.
BrowserShots.org

HTML Entity

SyntaxPreviewNameDec.code
&nbsp;   non-breaking space 160
&iexcl; ¡ inverted exclamation mark 161
&cent; ¢ cent sign 162
&pound; £ pound sign 163
&curren; ¤ currency sign 164
&yen; ¥ yen sign (yuan sign) 165
&brvbar; ¦ broken bar (broken vertical bar) 166
&sect; § section sign 167
&uml; ¨ diaeresis (spacing diaeresis) 168
&copy; © copyright sign 169
&ordf; ª feminine ordinal indicator 170
&laquo; « left-pointing double angle quotation mark 171
&not; ¬ not sign 172
&shy; ­ soft hyphen (discretionary hyphen) 173
&reg; ® registered sign (registered trade mark sign) 174
&macr; ¯ macron (spacing macron, overline APL overbar) 175
&deg; ° degree sign 176
&plusmn; ± plus-minus sign (plus-or-minus sign) 177
&sup2; ² superscript two (superscript digit two, squared) 178
&sup3; ³ superscript three (superscript digit three, cubed) 179
&acute; ´ acute accent (spacing acute) 180
&micro; µ micro sign 181
&para; pilcrow sign (paragraph sign) 182
&middot; · middle dot (Georgian comma, Greek middle dot) 183
&cedil; ¸ cedilla (spacing cedilla) 184
&sup1; ¹ superscript one (superscript digit one) 185
&ordm; º masculine ordinal indicator 186
&raquo; » right-pointing double angle quotation mark (guillemet) 187
&frac14; ¼ vulgar fraction one quarter 188
&frac12; ½ vulgar fraction one half 189
&frac34; ¾ vulgar fraction three quarters 190
&iquest; ¿ inverted question mark (turned question mark) 191
&Agrave; À Latin capital letter A with grave 192
&Aacute; Á Latin capital letter A with acute 193
&Acirc; Â Latin capital letter A with circumflex 194
&Atilde; Ã Latin capital letter A with tilde 195
&Auml; Ä Latin capital letter A with diaeresis 196
&Aring; Å Latin capital letter A with ring above 197
&AElig; Æ Latin capital letter AE (Latin capital ligature AE) 198
&Ccedil; Ç Latin capital letter C with cedilla 199
&Egrave; È Latin capital letter E with grave 200
&Eacute; É Latin capital letter E with acute 201
&Ecirc; Ê Latin capital letter E with circumflex 202
&Euml; Ë Latin capital letter E with diaeresis 203
&Igrave; Ì Latin capital letter I with grave 204
&Iacute; Í Latin capital letter I with acute 205
&Icirc; Î Latin capital letter I with circumflex 206
&Iuml; Ï Latin capital letter I with diaeresis 207
&ETH; Ð Latin capital letter ETH 208
&Ntilde; Ñ Latin capital letter N with tilde 209
&Ograve; Ò Latin capital letter O with grave 210
&Oacute; Ó Latin capital letter O with acute 211
&Ocirc; Ô Latin capital letter O with circumflex 212
&Otilde; Õ Latin capital letter O with tilde 213
&Ouml; Ö Latin capital letter O with diaeresis 214
&times; × multiplication sign 215
&Oslash; Ø Latin capital letter O with stroke 216
&Ugrave; Ù Latin capital letter U with grave 217
&Uacute; Ú Latin capital letter U with acute 218
&Ucirc; Û Latin capital letter U with circumflex 219
&Uuml; Ü Latin capital letter U with diaeresis 220
&Yacute; Ý Latin capital letter Y with acute 221
&THORN; Þ Latin capital letter THORN 222
&szlig; ß Latin small letter sharp s (ess-zed) 223
&agrave; à Latin small letter a with grave 224
&aacute; á Latin small letter a with acute 225
&acirc; â Latin small letter a with circumflex 226
&atilde; ã Latin small letter a with tilde 227
&auml; ä Latin small letter a with diaeresis 228
&aring; å Latin small letter a with ring above 229
&aelig; æ Latin small letter ae (Latin small ligature ae) 230
&ccedil; ç Latin small letter c with cedilla 231
&egrave; è Latin small letter e with grave 232
&eacute; é Latin small letter e with acute 233
&ecirc; ê Latin small letter e with circumflex 234
&euml; ë Latin small letter e with diaeresis 235
&igrave; ì Latin small letter i with grave 236
&iacute; í Latin small letter i with acute 237
&icirc; î Latin small letter i with circumflex 238
&iuml; ï Latin small letter i with diaeresis 239
&eth; ð Latin small letter eth 240
&ntilde; ñ Latin small letter n with tilde 241
&ograve; ò Latin small letter o with grave 242
&oacute; ó Latin small letter o with acute 243
&ocirc; ô Latin small letter o with circumflex 244
&otilde; õ Latin small letter o with tilde 245
&ouml; ö Latin small letter o with diaeresis 246
&divide; ÷ division sign 247
&oslash; ø Latin small letter o with stroke 248
&ugrave; ù Latin small letter u with grave 249
&uacute; ú Latin small letter u with acute 250
&ucirc; û Latin small letter u with circumflex 251
&uuml; ü Latin small letter u with diaeresis 252
&yacute; ý Latin small letter y with acute 253
&thorn; þ Latin small letter thorn with 254
&yuml; ÿ Latin small letter y with diaeresis 255
&fnof; ƒ Latin small f with hook (function, florin) 402
&Alpha; Α Greek capital letter alpha 913
&Beta; Β Greek capital letter beta 914
&Gamma; Γ Greek capital letter gamma 915
&Delta; Δ Greek capital letter delta 916
&Epsilon; Ε Greek capital letter epsilon 917
&Zeta; Ζ Greek capital letter zeta 918
&Eta; Η Greek capital letter eta 919
&Theta; Θ Greek capital letter theta 920
&Iota; Ι Greek capital letter iota 921
&Kappa; Κ Greek capital letter kappa 922
&Lambda; Λ Greek capital letter lambda 923
&Mu; Μ Greek capital letter mu 924
&Nu; Ν Greek capital letter nu 925
&Xi; Ξ Greek capital letter xi 926
&Omicron; Ο Greek capital letter omicron 927
&Pi; Π Greek capital letter pi 928
&Rho; Ρ Greek capital letter rho 929
&Sigma; Σ Greek capital letter sigma 931
&Tau; Τ Greek capital letter tau 932
&Upsilon; Υ Greek capital letter upsilon 933
&Phi; Φ Greek capital letter phi 934
&Chi; Χ Greek capital letter chi 935
&Psi; Ψ Greek capital letter psi 936
&Omega; Ω Greek capital letter omega 937
&alpha; α Greek small letter alpha 945
&beta; β Greek small letter beta 946
&gamma; γ Greek small letter gamma 947
&delta; δ Greek small letter delta 948
&epsilon; ε Greek small letter epsilon 949
&zeta; ζ Greek small letter zeta 950
&eta; η Greek small letter eta 951
&theta; θ Greek small letter theta 952
&iota; ι Greek small letter iota 953
&kappa; κ Greek small letter kappa 954
&lambda; λ Greek small letter lambda 955
&mu; μ Greek small letter mu 956
&nu; ν Greek small letter nu 957
&xi; ξ Greek small letter xi 958
&omicron; ο Greek small letter omicron 959
&pi; π Greek small letter pi 960
&rho; ρ Greek small letter rho 961
&sigmaf; ς Greek small letter final sigma 962
&sigma; σ Greek small letter sigma 963
&tau; τ Greek small letter tau 964
&upsilon; υ Greek small letter upsilon 965
&phi; φ Greek small letter phi 966
&chi; χ Greek small letter chi 967
&psi; ψ Greek small letter psi 968
&omega; ω Greek small letter omega 969
&bull; bullet (black small circle) 8226
&hellip; horizontal ellipsis (three dot leader) 8230
&prime; prime (minutes, feet) 8242
&Prime; double prime (seconds, inches) 8243
&oline; overline (spacing overscore) 8254
&frasl; fraction slash 8260
&trade; trade mark sign 8482
&larr; leftwards arrow 8592
&uarr; upwards arrow 8593
&rarr; rightwards arrow 8594
&darr; downwards arrow 8595
&harr; left right arrow 8596
&part; partial differential 8706
&prod; n-ary product (product sign) 8719
&sum; n-ary summation 8721
&minus; minus sign 8722
&radic; square root (radical sign) 8730
&infin; infinity 8734
&cap; intersection (cap) 8745
&int; integral 8747
&asymp; almost equal to (asymptotic to) 8776
&ne; not equal to 8800
&equiv; identical to 8801
&le; less-than or equal to 8804
&ge; greater-than or equal to 8805
&loz; lozenge 9674
&spades; black spade suit 9824
&clubs; black club suit (shamrock) 9827
&hearts; black heart suit (valentine) 9829
&diams; black diamond suit 9830
&quot; " quotation mark (APL quote) 34
&amp; & ampersand 38
&lt; < less-than sign 60
&gt; > greater-than sign 62
&OElig; ΠLatin capital ligature OE 338
&oelig; œ Latin small ligature oe 339
&Scaron; Š Latin capital letter S with caron 352
&scaron; š Latin small letter s with caron 353
&Yuml; Ÿ Latin capital letter Y with diaeresis 376
&circ; ˆ modifier letter circumflex accent 710
&tilde; ˜ small tilde 732
&zwnj; zero width non-joiner 8204
&zwj; zero width joiner 8205
&lrm; left-to-right mark 8206
&rlm; right-to-left mark 8207
&ndash; en dash 8211
&mdash; em dash 8212
&lsquo; left single quotation mark 8216
&rsquo; right single quotation mark 8217
&sbquo; single low-9 quotation mark 8218
&ldquo; left double quotation mark 8220
&rdquo; right double quotation mark 8221
&bdquo; double low-9 quotation mark 8222
&dagger; dagger 8224
&Dagger; double dagger 8225
&permil; per mille sign 8240
&lsaquo; single left-pointing angle quotation mark 8249
&rsaquo; single right-pointing angle quotation mark 8250
&euro; euro sign 8364

O blogu

Tento blog je místem, kde sdílím své zkušenosti, části zdrojových kódů, odkazy apod. Zdroje jsou zaměřeny převážně na problematiku portálového řešení SharePoint a vývoj webů v prostředí Microsoft. Mým cílem není úplně obsahnout konkrétní řešení, ale pouze tu část, kterou potřebuji. Pokud se problematika obsáhlejší, jsou pod článkem odkazy na související informace.

O autorovi

Oldřich Zátopek
Zabývám se vývojem webových aplikací internet/intranet na Microsoft technologiích. Hlavní specializace je SharePoint. LinkedIn