[Libreoffice-bugs] [Bug 132444] New: Base form created using the UNO API is not editable
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Sun Apr 26 22:15:21 UTC 2020
https://bugs.documentfoundation.org/show_bug.cgi?id=132444
Bug ID: 132444
Summary: Base form created using the UNO API is not editable
Product: LibreOffice
Version: 6.3.5.2 release
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Base
Assignee: libreoffice-bugs at lists.freedesktop.org
Reporter: prrvchr at gmail.com
Created attachment 159978
--> https://bugs.documentfoundation.org/attachment.cgi?id=159978&action=edit
biblio database with a non-editable form smtpMailerOOo
It seems that a Base form created using the API is not editable, it appears to
be a Draw document instead of a Write document.
You will find a copy of such a form in the attached biblio database (the form
called smtpMailerOOo) and will be able to see that the properties of the form
cannot be modified in Base even by choosing edit instead of open...
This form was created with the extension smtpMailerOOo
(https://github.com/prrvchr/smtpMailerOOo) under python with the following
code:
> def _getForm(self, create, name='smtpMailerOOo'):
> forms = self._database.DatabaseDocument.getFormDocuments()
> if forms.hasByName(name):
> form = forms.getByName(name)
> elif create:
> form = self._createForm(forms, name)
> else:
> return None, None
> args = getPropertyValueSet({'ActiveConnection': self.Connection,
> 'OpenMode': 'openDesign',
> 'Hidden': True})
> doc = forms.loadComponentFromURL(name, '', 0, args)
> return doc, form
> def _createForm(self, forms, name):
> service = 'com.sun.star.sdb.DocumentDefinition'
> args = getPropertyValueSet({'Name': name,
> 'ActiveConnection': self.Connection})
> form = forms.createInstanceWithArguments(service, args)
> forms.insertByName(name, form)
> form = forms.getByName(name)
> return form
Form creation is done without problem under OpenOffice 4.1x and 4.2.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20200426/6d5633ec/attachment.htm>
More information about the Libreoffice-bugs
mailing list