<html>
<head>
<base href="https://bugs.documentfoundation.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_UNCONFIRMED "
title="UNCONFIRMED - 'Format' Basic function doesn't handle Null values"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=143192">143192</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>'Format' Basic function doesn't handle Null values
</td>
</tr>
<tr>
<th>Product</th>
<td>LibreOffice
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>All
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>UNCONFIRMED
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>BASIC
</td>
</tr>
<tr>
<th>Assignee</th>
<td>libreoffice-bugs@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>mikekaganski@hotmail.com
</td>
</tr></table>
<p>
<div>
<pre>Format function's format string takes up to four sections separated by
semicolons. The fourth section is for Null values.
This is defined in SbxValue::Format, which handles SbxNULL values explicitly,
calling SbxBasicFormater::BasicFormatNull. However, calling
<span class="quote">> Format(Null)</span >
or
<span class="quote">> Format(Null, ";;;""NNN""")</span >
results in "Inadmissible value or data type. Data type mismatch" error.
This works in VBA [1]: the former call returns "", and the latter returns
"NNN".
[1]
<a href="https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/format-function-visual-basic-for-applications">https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/format-function-visual-basic-for-applications</a></pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>