Microsoft KB Archive/316332

= PRB: OLE Error Message &quot;0x80010105: The Server Threw an Exception&quot; When You Play a Sound =

Article ID: 316332

Article Last Modified on 9/27/2004

-

APPLIES TO

 Microsoft Visual FoxPro 5.0 Standard Edition, when used with:  Microsoft Windows 2000 Standard Edition

 Microsoft Windows 98 Standard Edition

 Microsoft Windows 98 Second Edition

 Microsoft Windows Millennium Edition</li></ul>

 Microsoft Windows NT 4.0</li></ul> </li> Microsoft Visual FoxPro 5.0a, when used with:  Microsoft Windows 2000 Standard Edition</li></ul>

 Microsoft Windows 98 Standard Edition</li></ul>

 Microsoft Windows 98 Second Edition</li></ul>

 Microsoft Windows Millennium Edition</li></ul>

 Microsoft Windows NT 4.0</li></ul> </li> Microsoft Visual FoxPro 6.0 Professional Edition, when used with:  Microsoft Windows 2000 Standard Edition</li></ul>

<ul> <li>Microsoft Windows 98 Standard Edition</li></ul>

<ul> <li>Microsoft Windows 98 Second Edition</li></ul>

<ul> <li>Microsoft Windows Millennium Edition</li></ul>

<ul> <li>Microsoft Windows NT 4.0</li></ul> </li> <li>Microsoft Visual FoxPro 7.0 Professional Edition, when used with: <ul> <li>Microsoft Windows 2000 Standard Edition</li></ul>

<ul> <li>Microsoft Windows 98 Standard Edition</li></ul>

<ul> <li>Microsoft Windows 98 Second Edition</li></ul>

<ul> <li>Microsoft Windows Millennium Edition</li></ul>

<ul> <li>Microsoft Windows NT 4.0</li></ul> </li></ul>

-

<div class="notice_section">

This article was previously published under Q316332

<div class="symptoms_section">

SYMPTOMS
If you play a .wav file that is stored in a general field by using an @ say command, you may receive the following error message:

OLE error code 0x80010105: The server threw an exception.

<div class="resolution_section">

RESOLUTION
To work around this problem, use a memo binary field instead of a general field. Copy the sound to a temporary file, and then use the set bell to command to play the sound. The following sample code demonstrates this method: * If the file already exists, you are not prompted to overwrite it. SET SAFETY OFF

CREATE TABLE testsound (sound M NOCPTRANS)
 * The NOCPTRANS clause makes this a binary memo field.

APPEND BLANK APPEND MEMO sound FROM GETFILE(&quot;wav&quot;)

COPY MEMO sound TO &quot;temp.wav&quot; SET BELL TO &quot;temp.wav&quot;, 1 ?? CHR(7) SET BELL TO
 * Copy the sound from the table to a file.

<div class="moreinformation_section">

Steps to Reproduce the Problem
<ol> <li> Run the following code. When the dialog box appears, select a .wav file: SET SAFETY OFF

CREATE TABLE testsound (sound G)

APPEND BLANK APPEND GENERAL sound FROM GETFILE(&quot;wav&quot;)

@1,1 SAY testsound.sound verb &quot;play&quot; </li> <li>If you are running one of the listed operating systems, you receive the error message that is mentioned in the &quot;Symptoms&quot; section.</li></ol>

Keywords: kbcodesnippet kbprb KB316332

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.