datepart函数示例. [英] datepart function example.

查看:93
本文介绍了datepart函数示例.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



请datepart函数示例.

我有如下的ASP 3.0代码.

nwd = DatePart("ww",j,2,2)

我想转换ASP.NET代码.

如果有人知道请.告诉我们该怎么做.因为我是ASP 3.0的新手.

Hi,

pls. datepart function example.

i have ASP 3.0 code as below.

nwd = DatePart("ww", j, 2, 2)

I want to convert ASP.NET code.

If anyone know pls. tell us how to do that. because i am new for ASP 3.0.

推荐答案

我怀疑它们是否是ASP 3.0中的任何"DatePart"函数.在.Net中,您可以从DateTime类型变量中获取如下的Year/Month/Day/Hour/Minute.

I doubt if their is any "DatePart" function in ASP 3.0. In .Net you can get Year/Month/Day/Hour/Minute as below from your DateTime type variable.

int year = DateTime.Now.Year;
int month = DateTime.Now.Month;
int day = DateTime.Now.Day;


这篇关于datepart函数示例.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆