Сообщений: 22664 Откуда: Ростов-на-Дону Дата регистрации: 05.05.2005
См. хелп set bell
Re: Как проиграть фрагмент из WAV файла ?
h.i.a.
Сообщений: 4001 Откуда: Мурманск/Спб Дата регистрации: 18.11.2005
Re: Как проиграть фрагмент из WAV файла ?
Влад Колосов
Сообщений: 22664 Откуда: Ростов-на-Дону Дата регистрации: 05.05.2005
set bell не поможет, но хелп по нему поможет там внизу есть интересная ссылка на FFC
Re: Как проиграть фрагмент из WAV файла ?
h.i.a.
Сообщений: 4001 Откуда: Мурманск/Спб Дата регистрации: 18.11.2005
Re: Как проиграть фрагмент из WAV файла ?
Emil Revencu Автор
Сообщений: 298 Дата регистрации: 25.11.2002
Извините, но в каком хелпе? Может ссылку дадите
P.S. Проигрывать нужно любой фрагмент (может быть и не с начала файла)
Re: Как проиграть фрагмент из WAV файла ?
h.i.a.
Сообщений: 4001 Откуда: Мурманск/Спб Дата регистрации: 18.11.2005
Re: Как проиграть фрагмент из WAV файла ?
piva
Сообщений: 18638 Откуда: Курган Дата регистрации: 24.03.2004
Кидаешь на форму МедиаПлер this.Open(. wav) this.SelectionStart=. this.SelectionEnd=.. Ну а потом когда ReadyState=4 можешь играть — и будет тебе кусок какой надо
Re: Как проиграть фрагмент из WAV файла ?
DOOR
Сообщений: 3 Дата регистрации: 25.04.2006
Re: Как проиграть фрагмент из WAV файла ?
piva
Сообщений: 18638 Откуда: Курган Дата регистрации: 24.03.2004
В системе стандлартно стоит — Win98- Win2K
Re: Как проиграть фрагмент из WAV файла ?
rvc44
Сообщений: 2211 Откуда: Тамбов Дата регистрации: 06.12.2005
Скачайте компонент, опубликованный 27.02.2006, который будет доступен в Microsoft Visual FoxPro 10 (Sedna), а пока все работают на VFP9SP1, называется так: Microsoft Visual FoxPro Sedna – Community Technology Preview (CTP) March 2006 отсюда download.microsoft.com.
Вот как представляет этот компонент его разработчик, фирма Microsoft:
В нем содержится очень полезная NET4COM.dll, являющаяся wrapper’ом VFP к функциональности достаточно широкого круга классов из Microsoft .NET Framework 2.0 (по крайней мере для решения Вашей задачи — точно!). Раньше не было возможности получить доступ к этим .NET-классам из под VFP. Грядущая интеграция VFP с .NET налицо!
NET4COM позволяет обращаться из VFP к большому числу полезных .NET-классов для работы с Clipboard, Mouse, Network, PowerStatus, Process, Regular expression, Registry, Services, а так же Audio.
Вот примеры обращений к Audio, доступных в .NET, а теперь и в VFP:
Play (String soundFile, Integer playMode)
Воспроизводит аудио-файл. Возвращает: ничего Параметры: soundFile: Строка. Файл для воспроизведения. playMode: Целое. playMode может принимать следущие значения: 0 WaitToComplete Воспроизводит звук и ждет пока он закончится перед выполнением последующего кода 1 Background Воспроизводит звук в фоне. Весь последующий код продолжает выполняться. 2 BackgroundLoop Воспроизводит звук в фоне до тех пор, пока не будет вызван метод Stop(). Весь последующий код продолжает выполняться.
Приостанавливает воспроизведение звука в фоне. Возвращает: ничего Параметры: нет
Наиболее гибкое управление задачами. Работает так, как нужно Вам!
Ошибка OLE 80020006
Ошибка OLE 80020006
Сообщение Yury A. » 12 май 2014, 21:06
Re: Ошибка OLE 80020006
Сообщение Alexandra » 13 май 2014, 15:13
1) пожалуйста поставьте MSXML6.
3) Проверьте, находится ли IE7 в online mode
Re: Ошибка OLE 80020006
Сообщение Yury A. » 13 май 2014, 19:36
Re: Ошибка OLE 80020006
Сообщение Yury A. » 13 май 2014, 19:46
Re: Ошибка OLE 80020006
Сообщение andrey » 15 май 2014, 12:04
Еще раз перепроверил на английском форуме. Для запуска MLO на crossover и чтобы работал Cloud Sync необходимо поставить msxml6 и ie7. Используют эти команды:
winetricks msxml6 winetricks ie7
Описанная Вами ошибка говорит о том что эти компоненты не поставлены. Перепроверьте.
Re: Ошибка OLE 80020006
Сообщение Денис » 12 дек 2014, 13:46
Re: Ошибка OLE 80020006
Сообщение Денис » 13 дек 2014, 09:53
Re: Ошибка OLE 80020006
Сообщение andrey » 18 дек 2014, 18:14
Из письма в поддержку мы узнали, что Вы используете crossover. Я лично не использую Crossover для запуска Windows приложений на Mac. Я не могу предоставить точных шагов как установить требуемые компоненты. Я лишь знаю теорию и передею здесь знания тех пользователей, которые настроили MLO на Mac под различные системы виртуализации.
Я знаю, что на Mac должны быть установлены два компонента, чтобы заработали синхронизация: IE7 (или старше) MSXML Parser 6.0
Я попробовал найти для вас в Google как это сделать на Crossover. Вот что у меня получилось:
Я не могу подтвердить что это заработает, т.к. не использую Crossover. Вы можете проверить и отписать здесь, что для Crossover это сработало?
Если не сработает, вы можете (как владелец crossover лицензии) обратиться в поддержку crossover и запросить как поставить требуемые компоненты?
Ошибка: System.Runtime.InteropServices.COMException (0x80020006): Неизвестное имя. (Exception from HRESULT: 0x80020006 (DISP_E_UNKNOWNNAME))
Ошибка: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. —> System.Runtime.InteropServices.COMException (0x000003E9): Program protection key not found! — End of inner exception stack trace — at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams) at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args) at Query1Сv81.Query1СBeg() in c:\Inetpub\td_wwwroot\App_Code\Common.cs:line 102 at Query1Сv81.Query1СOne(String pFunction, String pParam) in c:\Inetpub\td_wwwroot\App_Code\Common.cs:line 129 at produce.writeXmlFile(String strJava, String strLogin) in c:\Inetpub\td_wwwroot\produce.aspx.cs:line 201
Event Category: Firing Agent Description: The COM+ Event System failed to fire the GetObjectIdentity method on subscription . The subscriber returned HRESULT 80020006.
проблемы с регистрацией компонент. попробуй релиз платформы переустановить (на новый)
This forum has migrated to Microsoft Q&A. Visit Microsoft Q&A to post new questions.
Answered by:
Question
I’m trying to place an image in a specific point in a Word Document. I found the following code in the net:
This works, it places the image in the beginning of the document. But what I need to do is find a marker in the word document, (the text ##IMG##) and replace it with the image or place the image after that text expression.
Anyone knows how to do this?
Answers
The problem is that you’re trying to add the picture to the Range, rather than adding it to the document’s Shapes collection and passing the range as a parameter.
Take a look back up the thread at the syntax you posted for AddPicture. The two versions of AddPicture are actually used for different collections. I prefer to use the Shapes collection. That’s the one with the 8 params. So you’ll want something like:
It may turn out that you have to supply all those other parameters. Here’s the page that tells you what they represent:
All replies
The AddPicture method has an optional parameter (8th) that lets you specify a range to use as an anchor for the image.
Where are the two syntaxes I’ve found for AddPicture:
I suppose you are referring to the second one, it’s the only one with 8 parameters.
Anyway how can I define the anchor as to be the expression ##IMG## in order for that to be replaced with the picture?
Welcome to the MSDN forum.
After inserting picture , you can try the code in this example to replace the text to nothing. http://social.msdn.microsoft.com/Forums/en/vbide/thread/1558f560-8ae6-413a-bbc4-aa8d5d912aac
Have a nice day!
Shanks Zen MSDN Community Support | Feedback to us
The easiest way is to define the place you want the image as a bookmark ahead of time, and then set a range to that bookmark:
This approach works if you’re starting with a base document or template, which it sounds like you are.
Thank you for the idea. I’ve bookmarked the place in the Word document and tried every way i could to make this work but ‘m only getting OLE errors. Can you give-me an actual code example please?
Why don’t you show the code you’re trying and let us tweak it. Looking back at what I wrote on Friday, I realize that it probably needs Range() on the end:
Here are the two examples I’ve tried:
ypic=GETFILE(«bmp») oWord = CREATEOBJECT(«Word.Application») oDoc = oWord.Documents.OPEN(«d:\test.doc») oRange = oDoc.Bookmarks(«##IMG##»).Range() WITH oRange .AddPicture(yPic) ENDWITH oWord.QUIT(.T.) && Save changes
With this I get the following error: ErrCode: 1426, Info: OLE error code 0x80020006
ypic=GETFILE(«bmp») oWord = CREATEOBJECT(«Word.Application») oDoc = oWord.Documents.OPEN(«d:\test.doc») oRange = oDoc.Bookmarks(«##IMG##»).Range() WITH oRange .ActiveDocument.Shapes.AddPicture(yPic) ENDWITH oWord.QUIT(.T.) && Save changes
With this I get the following error: ERRO: ErrCode: 1943, Info: Member ACTIVEDOCUMENT does not evaluate to an object
Before trying any if this I bookmarked the word document with “##IMG#”
The problem is that you’re trying to add the picture to the Range, rather than adding it to the document’s Shapes collection and passing the range as a parameter.
Take a look back up the thread at the syntax you posted for AddPicture. The two versions of AddPicture are actually used for different collections. I prefer to use the Shapes collection. That’s the one with the 8 params. So you’ll want something like:
It may turn out that you have to supply all those other parameters. Here’s the page that tells you what they represent:
Where is a simplified version of the code i used:
Again. Thank you!
Jus tone more detail, if you know. The picture is placed align to the left of the page. How can I align the picture to the centre of the page? The paragraphs in that area of the document are align to centre.
Set the appropriate properties of the new Shape object after you add it. The property you’re looking for is WrapFormat.
I’ve changed the code from:
Now I’m getting the following error: ErrCode: 1426, Info: OLE error code 0x80020006
You’re getting that error because oRange isn’t the Shape object you just added. The AddShape method returns an object reference to the Shape you created. Grab that and use it:
Set the appropriate properties of the new Shape object after you add it. The property you’re looking for is WrapFormat.
Tamar, you’re doing an excellent job in this forum. Please send me an email: edprice at microsoft.
Ed Price (a.k.a User Ed), SQL Server Experience Program Manager (Blog, Twitter, Wiki)
I’ve changed the code as you suggested. I no longer get any errors but the picture is still align horizontally to the left of the page. I want the picture to be centred horizontally in the page. I’ve tried to change the oShape.WrapFormat.Type from zero to the following values: 7 (wdWrapInline); 3 (wdWrapNone); 2 (wdWrapThrough); 1 (wdWrapTight); 4 (wdWrapTopBottom) but still no luck.
My word is in Portuguese but I’m sure the position of thinks in the dialog boxes is the same in English.