与归期在asp.net C#中比较日期之旅 [英] Compare journey date with return date in asp.net c#
本文介绍了与归期在asp.net C#中比较日期之旅的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我要比较西游最新与返回日期。返程日期应大于等于行程日期。这验证器应该用于该&放大器;怎么样?
帮我。
Asp.net C#。
谢谢你。
I have to compare Journey date with return date. Return date should be Greater than equal to journey date. Which validator should be used for that & how? Help me. Asp.net c#. Thank you.
推荐答案
您可以使用的的CustomValidator 并为您在客户端或服务器端
You can use CustomValidator and check the validation in client-side or server-side
<asp:CustomValidator ID="cvComment" runat="server" ClientValidationFunction="clientCheckDateTime"
Enabled="true" Display="Dynamic" ControlToValidate="[Control ID]" Text="[Your Message]" />
<script language="javascript" type="text/javascript">
function clientCheckDateTime(source, arguments) {
arguments.IsValid = [Check Validation];
}
</script>
这篇关于与归期在asp.net C#中比较日期之旅的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文