-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi Tobias,
> But at the moment I don't find a solution how to select all content of a
> document. Which interface stores all the content?
AFAIK you can use something like this:
oSrcDoc.CurrentController.Select(oSrcSection.Anchor)
oDispatcher.executeDispatch(oSrcDispFrame, ".uno:Copy", "", 0, arr())
oDstDoc.CurrentController.Select(oDstSection.Anchor)
oDispatcher.executeDispatch(oDstDispFrame, ".uno:Paste", "", 0, arr())
This will copy a Textsection into a Dst document ...
Or you create a tmp autotext:
oCursor =
oSrcDoc.getText().createTextCursorByRange(oSrcSection.getAnchor().getStart())
oCursor.gotoRange(oSrcSection.getAnchor().getEnd(), True)
oATContainer = CreateUnoService("com.sun.star.text.AutoTextContainer")
' use last path for autotext containers, this should be the user
directory :-)
oATContainer.insertNewByName("TMP" & "*" &
CStr(oATContainer.getCount()-1))
oATGroup = oATContainer.getByName("TMP")
oATGroup.insertNewByName("TMP", "TMP", oCursor)
oCursor =
oDstDoc.getText().createTextCursorByRange(oDstSection.getAnchor().getStart())
oATGroup.getByName("TMP").applyTo(oCursor)
HTH
Oliver
- --
GnuPG key 0xCFD04A45: 8822 057F 4956 46D3 352C 1A06 4E2C AB40 CFD0 4A45
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFZvp1TiyrQM/QSkURAkFEAJ4xVacWCwVFvy9WBTADhkwYP0sN6wCdHRGr
kd4TUjIYEwbJ3htJyhq5vHs=
=+mOO
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]