Page 1 of 1

[Solved] "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 9:46 am
by charlie.it
Hello everybody, often I help to solve Base problems on Italian OO forum and I download and modify files .odb loaded by users.
Sometimes, when I reopen a Form after saved it, I obtain this error:"SfxBaseModel::loadFromStorage: 0xf26" and it does'n work more.
That does'nt happen with my databases, writed by me.
I use LibreOffice 6.4.6.2 with macOS 10.12 Sierra.
Can you helpl me? Thanks.
I attach database examples before/after problem (form: "f_anagrafica")
After.odb
(42.64 KiB) Downloaded 482 times
Before.odb
(41.51 KiB) Downloaded 474 times

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 10:26 am
by RoryOF
Might this simply be a race condition, Charlie? That before you can access the form after modification, there is need for a little time to allow OpenOffice do other housekeeping things before it is ready to permit you access the form.

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 10:28 am
by Villeroy
Delete the form and replace it with the backup from Before.odb. Drag the form icon from Before.odb to After.odb

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 11:36 am
by charlie.it
@RoryOF, thanks. No the form does'nt work also now. Can you open it? I don't think so.

@Villeroy, thanks. I'm sorry, maybe I haven't explained enough that the form in After file has been modified by placing (right clic > replace with) a listbox on a formatted field and using sql code as content. As long as I don't save, close and reopen the form, the listbox works perfectly. It is something I do normally but in my databases it does not give problems, in those attached by the users of the forum, sometimes it does.

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 6:42 pm
by MrProgrammer
charlie.it wrote:Sometimes, when I reopen a Form after saved it, I obtain this error:"SfxBaseModel::loadFromStorage: 0xf26" and it doesn't work more.
That doesn't happen with my databases, written by me. I use LibreOffice 6.4.6.2 with macOS 10.12 Sierra.
The Before.odb file was written by LibreOffice 7.0.4.2 so I think there is an incompatibility between that and your version, or there is a problem with this type of form which one of the versions does not handle correctly. Note that your office:version level is lower than the Before.odb file. Here is what is in f_anagrafica (forms/Obj11/meta.xml):
Before → <office:document-meta … office:version="1.3">
Before → <meta:generator>LibreOffice/7.0.4.2$MacOSX_X86_64 … </meta:generator>

After → <office:document-meta … office:version="1.2">
After → <meta:generator>LibreOffice/6.4.7.2$MacOSX_X86_64 … </meta:generator>
Comparing their content.xml with diff -y, I find:
______________________ Before _______________________________   ______________________ After _______________________________
<office:document-content xmlns:css3t="http://www.w3.org/TR/cs |	<office:document-content xmlns:officeooo="http://openoffice.o
							      >	xmlns:drawooo="http://openoffice.org/2010/draw"
							      >	xmlns:calcext="urn:org:documentfoundation:names:experimental:
							      >	xmlns:tableooo="http://openoffice.org/2009/table"
							      >	xmlns:oooc="http://openoffice.org/2004/calc"
							      >	xmlns:ooow="http://openoffice.org/2004/writer"
							      >	xmlns:css3t="http://www.w3.org/TR/css3-text/"
xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop <
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0"   <
xmlns:loext="urn:org:documentfoundation:names:experimental:of <
xmlns:officeooo="http://openoffice.org/2009/office"	      <
							      >	xmlns:rpt="http://openoffice.org/2005/report"
xmlns:tableooo="http://openoffice.org/2009/table"	      <
xmlns:rpt="http://openoffice.org/2005/report"		      <
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2"	      <
xmlns:dc="http://purl.org/dc/elements/1.1/"		      <
xmlns:calcext="urn:org:documentfoundation:names:experimental: <
xmlns:oooc="http://openoffice.org/2004/calc"		      <
xmlns:drawooo="http://openoffice.org/2010/draw"		      <
xmlns:ooo="http://openoffice.org/2004/office"		      |	xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop
xmlns:ooow="http://openoffice.org/2004/writer"		      |	xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compat <
							      >	xmlns:dc="http://purl.org/dc/elements/1.1/"
							      >	xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compat
							      >	xmlns:loext="urn:org:documentfoundation:names:experimental:of
							      >	xmlns:ooo="http://openoffice.org/2004/office"
							      >	xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2"
office:version="1.3">					      |	office:version="1.2">
							      >	<style:style style:name="gr3" style:family="graphic"
							      >	style:data-style-name="C10000">
							      >	<style:graphic-properties fo:background-color="#dddddd" />
							      >	</style:style>
							      >	<number:number-style style:name="C10000" number:language="it"
							      >	number:country="IT">
							      >	<number:number number:min-integer-digits="1" />
							      >	</number:number-style>
xml:id="control8" form:id="control8" form:current-value="0"   |	xml:id="control8" form:id="control8" form:value="0"
form:value="0" form:data-field="Numero Tessera"		      |	form:data-field="Numero Tessera" form:input-required="true"
form:input-required="true" form:convert-empty-to-null="true"  |	form:convert-empty-to-null="true" form:min-value="0"
form:min-value="0" form:max-value="100000">		      |	form:max-value="100000">
<form:text form:name="txtcome ci hai conosciuto"	      |	<form:listbox form:name="txtcome ci hai conosciuto"
form:control-implementation="ooo:com.sun.star.form.component. |	form:control-implementation="ooo:com.sun.star.form.component.
xml:id="control28" form:id="control28" form:input-required="f |	xml:id="control28" form:id="control28" form:dropdown="true"
form:convert-empty-to-null="true">			      |	form:data-field="come ci hai conosciuto"
							      >	form:input-required="false" form:bound-column="1"
							      >	form:list-source-type="sql"
							      >	form:list-source="SELECT "come ci hai conosciuto", 
							      >
office:string-value="com.sun.star.form.control.TextField" />  |	office:string-value="com.sun.star.form.control.ListBox" />
							      >	<form:list-property form:property-name="DefaultSelection"
							      >	office:value-type="float" />
							      >	<form:list-property form:property-name="TypedItemList"
							      >	office:value-type="float" />
</form:text>						      |	</form:listbox>
<draw:control draw:name="Forma3" draw:style-name="gr2"	      |	<draw:control draw:name="Forma3" draw:style-name="gr3"

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 8:11 pm
by Ratslinger
This is a known bug in LibreOffice. V6.x to v7.0 is OK. Anything created or modified in v7.0 then modified in earlier versions have the problem. Can edit to resolve.

https://bugs.documentfoundation.org/sho ... ?id=138209

Comments there to fix a form or not use ODF-version 1.3

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 10:07 pm
by Villeroy
Oh, this is bad. I thought it was a random problem with one of my forms and just restored it from backup. Good to know. Am I right that it is necessary to create a second version of a form when editing with LO 7.0 is inevitable?

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Thu Mar 11, 2021 10:29 pm
by Ratslinger
@Villeroy not certain creating a second form is the way to go. Possibly up to each as their situation dictates.

One solution is to set LibreOffice to not use ODF-version 1.3. This is in Tools->Options under Load/Save->General. Another is when the error occurs to modify the content.xml file for the form and set it back to:

office:version="1.3"

The 1.3 is set in LO 7.x and when modified in v6.x it is set to 1.2 and then will produce the error and not work. Changing it back to 1.3 gets it working again.

Which direction to take is up to each person. If enough switching between versions, possibly setting LO to 1.2 but then 1.3 benefits (don't know what this may be) are lost. I have taken the route of setting LO to 1.2 Extended and all seems fine thus far.

Re: "SfxBaseModel::loadFromStorage: 0xf26" Error

Posted: Fri Mar 12, 2021 1:08 pm
by charlie.it
For me was important to understand what happens, not repair the After.odb file.
Thanks to @MrProgrammer and @Ratslinger I understood that the error occurs when I open an save a file.odb created with 1.3 ODF version, using the 1.2 version of LibreOffice 6.x.x.
Thanks to all.