VB6日期数据类型:精度和格式 [英] VB6 Date data type: precision and formatting

查看:129
本文介绍了VB6日期数据类型:精度和格式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


  1. VB6 Date 数据类型的精确度(以秒为单位)吗?

  2. 如何格式化它以显示秒的小数部分?

  1. How precise is the VB6 Date data type (by way of fractions of a second)?
  2. How to format it to show fractions of a second?

我在多年缺席之后重新访问VB6,终生我当中的人不记得我曾经知道的事情。我考虑过放置内存泄漏

I'm revisiting VB6 after many years absence, and for the life of me can't remember the things I used to know. I considered putting a memory-leak tag on this, because my memory leaked (hur hur hur).

此后,我发现此API调用,并且似乎可以正常工作:

I found this API call afterwards, and it seems to work:

Declare Sub GetSystemTime Lib "kernel32.dll" (lpSystemTime As SystemTime)

Public Type SystemTime
  Year As Integer
  Month As Integer
  DayOfWeek As Integer
  Day As Integer
  Hour As Integer
  Minute As Integer
  Second As Integer
  Milliseconds As Integer
End Type


推荐答案

1)仅秒,并且

2)没办法。

这篇关于VB6日期数据类型:精度和格式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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