在Windows 8 metro中是否有任何像RequiredFeild控件(asp.net)的控件?我有一個簡單的幾個文本框,我只是想確保在文本框爲空時不要提交它。我知道在代碼中很容易,但我很想知道是否有其他方法?防止在Windows 8 Metro應用程序中提交空文本框
3
A
回答
2
您可能需要使用WinRT XAML Toolkit:
TextBoxValidationExtensions - 擴展,允許指定 格式要求的文本輸入以及刷子用來 亮點與有效或無效文字文本框。
我假設你確實想驗證輸入。
0
爲什麼你不使用String.IsNullOrEmpty()?
1
這是我發現的另一種解決方案。
相關問題
- 1. 如何在Windows 8 metro應用程序中提供用戶提示對話框?
- 2. Windows 8應用程序和Windows Phone應用程序提交
- 3. Windows Phone 8應用程序提交
- 4. 如何防止/禁用Windows 8 Metro UI應用程序的快照視圖
- 5. Windows 8 Metro應用程序 - 渲染PNGs
- 6. Windows 8 Metro應用程序Iframe
- 7. DateTime.Now - Metro應用程序 - Windows 8
- 8. HtmlAgilityPack和Windows 8 Metro應用程序
- 9. SQlite與Windows 8 Metro應用程序
- 10. 將資源文件包含在Windows 8 Metro應用程序中
- 11. 防止ASP.NET文本框提交表單
- 12. 在Windows 8上實現驗證Metro Metro應用程序
- 13. 在Windows 8 Metro綁定超鏈接到richtextblock Metro應用程序
- 14. 在Windows 8 Metro應用
- 15. Windows 8從桌面應用程序啓動「metro」應用程序?
- 16. Windows 8 Metro Style應用程序:多應用程序包
- 17. Windows 8 Metro應用程序中的可下載文件路徑?
- 18. 使用Windows 8/WinRT在Metro應用程序中啓用
- 19. Windows 8 Metro應用程序對話框更改字體顏色
- 20. Windows 8:如何在Windows 8中使用外部圖像Metro應用程序
- 21. 在Windows 8 metro應用程序中使用iframe
- 22. 將用戶數據存儲在Windows 8 metro應用程序中
- 23. 在Windows 8 Metro中禁用應用程序睡眠
- 24. 當文本框爲空並防止提交按鈕提交時的警報
- 25. 防止Windows Phone 8中的彈跳效果應用程序
- 26. 防止頁面擴展在Windows 8 XAML應用程序在ScrollView內的框架
- 27. Windows 8的Metro風格應用程序樣本
- 28. 使用Windows 8 Metro應用
- 29. 如何在Metro(Windows 8)應用程序中檢測Alt?
- 30. RichTextBlockOverflow.HasOverflowContent在Windows 8 Metro應用程序中始終爲false