Need help for clearing document metadata.

The Application Programming Interface and the OASIS Open Document Format

Need help for clearing document metadata.

Postby neo_ankit » Mon Sep 29, 2008 11:07 am

Hi,

I am writing a scrubber tool for open office document. The tool will clear all the crucial meta data from the file( Meta data may include Templates, editing time, user created, user modified, track changes etc).

I have reached till here:-
Code: Select all   Expand viewCollapse view
private void DeleteAllProperties(XFrame document)
{
//Get Local Context Object
XComponentContext localContext = uno.util.Bootstrap.bootstrap();

//Create service factory object used to create objects and to access
//different Services
XMultiServiceFactory multiServiceFactory = (XMultiServiceFactory)localContext.getServiceManager();

XDispatchHelper disp = (XDispatchHelper)multiServiceFactory.createInstance("com.sun.star.frame.DispatchHelper");

PropertyValue[] properties = new PropertyValue[10];
properties[2] = new PropertyValue();
properties[2].Name = "Properties.Title";
properties[2].Value = new Any("");

properties[3] = new PropertyValue();
properties[3].Name = "Properties.Subject";
properties[3].Value = new Any("");

disp.executeDispatch((XDispatchProvider)document, ".uno:SetDocumentProperties", "", 0, properties);
}

What I need now is a list of all the supported properties by Open office 2.4( Like we have Properties.Title and Properties.Subject in the code above).

Please help.

Thanks in advance.

Regards,
Ankit
User avatar
neo_ankit
 
Posts: 6
Joined: Fri Sep 26, 2008 3:31 pm

Re: Need help for clearing document metadata.

Postby Hagar Delest » Mon Sep 29, 2008 11:11 am

Since you've created a new thread, I've deleted your last post in your first thread and tagged it as solved.
I've moved this one in the UNO API and ODF forum.
AOO 4.1.6 on Xubuntu 19.04 and 4.1.5 on Windows 7 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28495
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Need help for clearing document metadata.

Postby neo_ankit » Tue Sep 30, 2008 7:57 am

All the mighty programmers of the world...please respond...........
OOo 2.4.X on Ms Windows XP
User avatar
neo_ankit
 
Posts: 6
Joined: Fri Sep 26, 2008 3:31 pm

Re: Need help for clearing document metadata.

Postby neo_ankit » Wed Oct 01, 2008 10:19 am

Ok..If nobody is supoosed to programming related queries here..this forum should be closed forever.

I regret even thinking of posting here.
OOo 2.4.X on Ms Windows XP
User avatar
neo_ankit
 
Posts: 6
Joined: Fri Sep 26, 2008 3:31 pm

Re: Need help for clearing document metadata.

Postby Hagar Delest » Wed Oct 01, 2008 10:26 am

neo_ankit wrote:Ok..If nobody is supoosed to programming related queries here..this forum should be closed forever.

I regret even thinking of posting here.

This is a user to user forum (see the Survival Guide for the forum). And very few users do such coding (should be clear according to the number of threads in this forum sub-section).
AOO 4.1.6 on Xubuntu 19.04 and 4.1.5 on Windows 7 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28495
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Need help for clearing document metadata.

Postby neo_ankit » Wed Oct 01, 2008 10:32 am

Now this is really irritating...

My post was first moved from one forum to another and now I am getting no proper response.

If possible just point me to a proper place where my query can be resolved...
User avatar
neo_ankit
 
Posts: 6
Joined: Fri Sep 26, 2008 3:31 pm

Re: Need help for clearing document metadata.

Postby Hagar Delest » Wed Oct 01, 2008 10:49 am

neo_ankit wrote:My post was first moved from one forum to another and now I am getting no proper response.

Your post was in the Writer forum, do you think there are many devs looking at this forum? And BTW, I left a shadow of your thread so that if that happens, he will see your thread (as a link).

neo_ankit wrote:If possible just point me to a proper place where my query can be resolved...

Why not try yourself to look for a more coding dedicated forum?

neo_ankit wrote:Now this is really irritating...

Indeed. For both of us. But remember that we are volunteers, we help other users on our free time, we are not paid. I took time to improve the visibility of your question but the forum is not responsible for lack of answer in your needed timing. If you're not satisfied, just hire a developer to do it. There is a sub-forum section (Paid support) where you can get some contacts. If you want to get that for free, then, just wait or get some documentation (SDK for example).

Last post in this thread.
Good luck.
AOO 4.1.6 on Xubuntu 19.04 and 4.1.5 on Windows 7 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28495
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Need help for clearing document metadata.

Postby Villeroy » Wed Oct 01, 2008 11:28 am

I added the code tags for better readability. The code looks like Java. You may want to install Object Inspector
Normally I stopped answering API related questions if they require nothing more than looking up the right interface.
http://api.openoffice.org/docs/common/r ... plier.html
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04, no OpenOffice, LibreOffice 6.x
User avatar
Villeroy
Volunteer
 
Posts: 26875
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Need help for clearing document metadata.

Postby neo_ankit » Wed Oct 01, 2008 11:32 am

Thank you Villeroy,

The code is actually in C#..but hope I will reach somewhere now.

Regards,
Ankit
OOo 2.4.X on Ms Windows XP
User avatar
neo_ankit
 
Posts: 6
Joined: Fri Sep 26, 2008 3:31 pm


Return to UNO API and ODF

Who is online

Users browsing this forum: moto and 0 guests