Link to home
Create AccountLog in
Avatar of martyje
martyje

asked on

reading the data from Word "developer controls"

Hi, is there any way to get the data out of Word Documenet "Developer Controls"?
word-developer-controls.jpg
Avatar of jpeca
jpeca
Flag of Serbia image

For some built-in content controls you can reference them directly (Title  for example):
Quick Part -> Fields  -> DocProperty
For custom content control i can't find how directly reference it, but you can define bookmark on content controle and then reference it by REF field
REF BookmarkName
Avatar of martyje
martyje

ASKER

Can I get that data into an xml file?
here's what I am trying to figure out. I am working on a news website where all the editors use MS word 2007. I am trying to take all the data from the word document and move it to the database or an xml file. I just thoght maybe I can use these content controls for that purpose?
thanks.
ASKER CERTIFIED SOLUTION
Avatar of jpeca
jpeca
Flag of Serbia image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of martyje

ASKER

Sounds like that's what I am looking for. In that article, he added Rich Text Box, just wondering I didn't find that anywhere in the controls, any suggestions? just want to follow the example as it is.
Thanks much.
Avatar of martyje

ASKER

I got to the mapped XML file which do has the data coming from MS word. So, every time I need the data, I 'd have to zip the file and then get that XML file? is there any other way?
Also, I lose all the formating, any Bold, Italic or any links stuff.
Thanks.
You need application which read information from Word document (Open XML format) and populate database. You can use VSTO to develop the application. Information how to do it you can find at Office Development Center http://msdn2.microsoft.com/en-us/library/bb739835.aspx
Avatar of martyje

ASKER

Is there any simple way to do that? I am a PHP programmer so VS... not a good idea for me.
Thanks.