Sign in to follow this  
Followers 0
Noobster24

Information about files and dirs

3 posts in this topic

#1 ·  Posted (edited)

Hi,

I can't find these kind of functions in the help file neither can I find them on the forum.

- Function to return true if $var is a file or return false if $var is directory

- Function to get extented info about file / directory (like create date, last modified date)

Hope someone got info about those functions.

So long,

Andreas

//Edit:

Found this one:

http://www.autoitscript.com/forum/index.ph...l=date+modified

Now I got one question more:

I use _FileListToArray(), I put those in my Listview, but those are ordered by name, I want to order them first by directory / file and then by filename. (Like in Windows Explorer).

How do I do that?

Edited by Noobster24

Programs so far:Teh Serializer - Search for licenses for Nero - Windows - Office - Alcohol etc.

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

What keywords did you use in your search? I'm guessing when you searched Help for functions that started with "File", that FileFindFirstFile nor FileGetTime() suit your needs? Perhaps in the future you can explain why a function doesn't work for you then explain what you're trying to accomplish. If I understand your message, you're looking for a funtion that will tell you an object is a file or a directory? It almost sounds like you want the information a dir provides. Have you looked at the example code in the Help file under the function Run()?

Edit: Good job finding an answer, still don't know why you didn't find that function the first time. But that's not important. So you want something like "dir *.* /O:G"? Can you figure it out with the information I provided a moment ago using the Help file example code??? I think you can, I think you can, I think you can.... like The Little Red Train <choo choo> :) Btw, good job your Serializer. Is it suppose to be "Teh" or "The" in your signature?

Edited by ssubirias3

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

What keywords did you use in your search? I'm guessing when you searched Help for functions that started with "File", that FileFindFirstFile nor FileGetTime() suit your needs? Perhaps in the future you can explain why a function doesn't work for you then explain what you're trying to accomplish. If I understand your message, you're looking for a funtion that will tell you an object is a file or a directory? It almost sounds like you want the information a dir provides. Have you looked at the example code in the Help file under the function Run()?

Edit: Good job finding an answer, still don't know why you didn't find that function the first time. But that's not important. So you want something like "dir *.* /O:G"? Can you figure it out with the information I provided a moment ago using the Help file example code??? I think you can, I think you can, I think you can.... like The Little Red Train <choo choo> :) Btw, good job your Serializer. Is it suppose to be "Teh" or "The" in your signature?

Thanks for the reply.

I solved it like this:

$dirarray = _FileListToArray($location,'*.*',2)

$filearray = _FileListToArray($location,'*.*',1)

So first I walk with For trough $dirarray and put in in my listview, then the same walk again but now with $filearray.

I thought I would be original if I used 'teh' instead of 'the'.

But I got another question, this time about a listview column. I would like to use GUICtrlSetBkColor() (or some other look-a-like function) that sets the background color of one column in the listview.

E.g. you got:

$listview = GuiCtrlCreateListView ('Name|Size|Type|Date Modified', $listviewleft, $listviewtop, $listviewwidth, $listviewheight)

I would like to set the background color of the Name column to 0xEEEEEE is that possible?

Edited by Noobster24

Programs so far:Teh Serializer - Search for licenses for Nero - Windows - Office - Alcohol etc.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0