From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can you edit file properties using Labview?

Except for the file attributes like 'read-only' and 'hidden', Windows 2000 & XP also have file properties like 'keywords', 'comments' and 'description'.

Is there any way that I can edit these properties in Labview?
0 Kudos
Message 1 of 12
(7,949 Views)
I looked around a bit and as far as I know there is not a way to do this, at least not a straightforward method to changing these properties in LabVIEW.
0 Kudos
Message 2 of 12
(7,949 Views)
Hi,

This technique is platform dependent. So if you want to do this for windows,
you'll have to use windows API's.

It is probably a Windows Shell thing. If you want to know about this, you
can ask about it in a windows programming newsgroup, e.g. VC++. We can help
you with the calling of API's in LabVIEW if you show us the C code...

And when you're done, I'm sure people in this newsgroup are interrested in
the VI's (and you'll get eternal fame)!

Regards,

Wiebe.


"blimpie boy" wrote in message
news:50650000000500000099C20000-1031838699000@exchange.ni.com...
> I looked around a bit and as far as I know there is not a way to do
> this, at least not a straightforward method to changing these
> properties in LabVIEW.
0 Kudos
Message 3 of 12
(7,947 Views)
I have got this from somewhere (not very sure:p can't recall)

However, jus see if it helps.

regards
Ian F
Since LabVIEW 5.1... 7.1.1... 2009, 2010, 2014
依恩与LabVIEW
LVVILIB.blogspot.com
0 Kudos
Message 4 of 12
(7,947 Views)
Looks like that Win32_API.llb file has calls to the Kernel32.dll file.  Of course, it has the File Attributes working in it, but no File Properties.  Unfortunately as that is what I was looking for, but oh well.  If I get it working, I will post something here.


0 Kudos
Message 5 of 12
(7,723 Views)
Rich, are their any fruits from your file properties project?
0 Kudos
Message 6 of 12
(7,634 Views)
nope, we never got that far and I am no longer on that project. 🙂
0 Kudos
Message 7 of 12
(7,625 Views)


@RichElswick wrote:
nope, we never got that far and I am no longer on that project. 🙂


And it would be a bitch to implement. Basically those properties are implement using propertysheet handlers. That are shell extensions that can be installed in Windows and in the registry added to one or more file types. On loading the property dialog the shell (basically only an Explorer thing) sees that for that specific file type there are property sheet handlers registered and then loads them as an extra property sheet into the dialog.
There is no common API to retrieve and lets forget about changing the information those property sheet handlers deal with programmatically. And every property sheet handler retrieves the actual properties according to his own private information, such as image properties in JPG files but possible also extra information in the meta data of a file on advanced files systems such as NTFS (the security property sheet for instance).
So you would have to create a Windows dialog, load the according property sheet handlers into it and then have the user deal with that interactively. I doubt that this is what you want.

Rolf Kalbermatter

Rolf Kalbermatter
My Blog
0 Kudos
Message 8 of 12
(7,619 Views)
It does sound like the effort outweighs the gain. Thanks for putting me off.
0 Kudos
Message 9 of 12
(7,603 Views)
Somehow I achieved what you've asked. But in my case I only included the options to access the "Read only, Hidden, System, Archive" file properties. And also I have attached the code here.
0 Kudos
Message 10 of 12
(4,232 Views)