How do you get the DateTime stamp of a text file using VB 6.0? By DateTime, I mean the date and time when the text file was created or modified. Sample code will be appreciated. Thank.
For the created / last change, you can simply:
dateVar = FileDateTime("c:\foo\bar\qux.file")
Use the method GetFilein FileSystemObjectand then just use the properties DateCreatedand 'DateLastModified'.
GetFile
FileSystemObject
DateCreated
Here's the sample documentation for how to do this from VBscript (almost the same from VB6):
http://msdn.microsoft.com/en-us/library/sheydkke%28VS.85%29.aspx
, FileSystemObject .
MS
Please note that the example works in VBScript, and also in VB6 you can get the file http://msdn.microsoft.com/en-us/library/aa716288(VS.60).aspx
t
Dim fso As New FileSystemObject, fil As File Set fil = fso.GetFile("c:\test.txt")
How about this:
Dev X: get datetime in VB6
Source: https://habr.com/ru/post/1745701/More articles:Build an OpenGL model in parallel? - c ++Is using Windows scripting, especially for FileSystemObject, a good idea? - vb6Any HTML tags inside the tooltip cause the main tooltip to close when hovering - javascriptHow to find if a network path is available or not - vb6How to extract a directory from a file path string? - pathHow can I stop re-building cruise control after a failed build? - email-spamReflector problem when decompiling a WPF assembly (i.e. PresentationCore, PresentationFramework) - wpfNServiceBus determines the execution order of handlers - c #Teamcity - build number - go to ant script - javaРеляционный клаузальный логический вопрос: что такое интерпретация Хербранда - logicAll Articles