Bug 78620

Summary: Microsoft Word input field become static when using libreoffice (wdFieldFormTextInput)
Product: LibreOffice Reporter: AngelBlueSky <tazzi>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED DUPLICATE    
Severity: blocker CC: jalojo
Priority: medium    
Version: unspecified   
Hardware: All   
OS: Windows (All)   
Whiteboard:
Crash report or crash signature: Regression By:
Attachments: Word document with input field

Description AngelBlueSky 2014-05-12 18:29:21 UTC
Created attachment 98937 [details]
Word document with input field

Sorry to write again but I got no answer last time.
I can work on word input field using openoffice via reflection (inserting, compiling etc etc), but I can't do the same with libreoffice, whenever I open a word document containing those text fields they become simple text!
LibreOffice_4.2.4
Comment 1 Jacques Guilleron 2014-05-13 15:18:00 UTC
Hello AngelBlueSky,

Importing your aaa.doc in LO 4.2.4.1 & Windows 7 Home Premium, I get a text field, not as a simple text.

Jacques
Comment 2 AngelBlueSky 2014-05-13 17:40:35 UTC
(In reply to comment #1)
> Hello AngelBlueSky,
> 
> Importing your aaa.doc in LO 4.2.4.1 & Windows 7 Home Premium, I get a text
> field, not as a simple text.
> 
> Jacques

Ok but are you able to get the bookmark of that field, I don't think so!!!

With openoffice I can get all text field like this, opening a file like the one I sent:
Object OOTextFields = OODoc.GetType().InvokeMember("getTextFields", BindingFlags.InvokeMethod, null, OODoc, new object[0]);

Object x = OOTextFields.GetType().InvokeMember("createEnumeration", BindingFlags.InvokeMethod, null, OOTextFields, new object[0]);

//MessageBox.Show(x.GetType().InvokeMember("hasMoreElements", BindingFlags.InvokeMethod, null, x, null).ToString());

while ((bool)x.GetType().InvokeMember("hasMoreElements", BindingFlags.InvokeMethod, null, x, null))
{
//do anything
}

with LO I can't enumerate any field! Trust me if I say it's a Bug!
Thanks anyway.
Comment 3 AngelBlueSky 2014-05-13 17:43:06 UTC
The line:

MessageBox.Show(x.GetType().InvokeMember("hasMoreElements", BindingFlags.InvokeMethod, null, x, null).ToString());

gives me FALSE!!!

Also triybg to enumerate bookmarks give me 0!!!

object myBookmarks = OODoc.GetType().InvokeMember("getBookmarks", BindingFlags.InvokeMethod, null, OODoc, new object[0]);
object myBookmarksCount = oBookmarks.GetType().InvokeMember("getCount", BindingFlags.InvokeMethod, null, oBookmarks, new object[0]);
int nCount = (int)myBookmarksCount;
MessageBox.Show(nCount.ToString());
Comment 4 Yousuf Philips (jay) (retired) 2014-05-30 02:16:14 UTC
*** Bug 79401 has been marked as a duplicate of this bug. ***
Comment 5 Yousuf Philips (jay) (retired) 2014-05-30 02:17:15 UTC

*** This bug has been marked as a duplicate of bug 78470 ***