|
![]() |
#1 |
Участник
|
EVGL спасибо!
Нашел вот еще классец GatewayQueryMSMQReceive. Там вроде как раз чтение из очереди... А постоянное чтение прийдется, как я понимаю, пакетником организовывать. |
|
![]() |
#2 |
Banned
|
Цитата:
X++: void ScanDirectory(FilePath _folderPath, GatewayOrgId _gatewayOrgId) { int hndFile; boolean showInfo = true; FileName scanFileName; ProblemGatewayImportProtocol importProtocol; ; if (! _folderPath) throw error("@SFI525"); if (! _gatewayOrgId) throw error("@SFI529"); if (! WinAPI::folderExists(_folderPath)) throw error( strfmt("@SFI526", _folderPath) ); gatewayOrgId = _gatewayOrgId; [hndFile, scanFileName] = WinAPI::findFirstFile(_folderPath + "\\*.tmp"); while (scanFileName) { fileName = _folderPath + scanFileName; if (!ProblemGatewayImportProtocol::exist(fileName)) { if (showInfo) { info("@SFI527"); showInfo = false; } importProtocol.clear(); importProtocol.FilePath = fileName; importProtocol.GatewayOrgId = gatewayOrgId; try { this.run(); importProtocol.ImportStatus = ImportStatus::Imported; } catch { importProtocol.ImportStatus = ImportStatus::InvalidFile; } importProtocol.insert(); } scanFileName = WinAPI::findNextFile(hndFile); } } ![]() Последний раз редактировалось EVGL; 04.04.2007 в 13:23. |
|
![]() |
#3 |
Участник
|
Цитата:
Вот пробую простенький примерчик X++: static void MSMQ_send(Args _args) { #MSMQ MSMQQueueInfo queueInfo; MSMQQueue queue; MSMQMessage message; MSMQTransactionDispenser dispenser = new MSMQTransactionDispenser(); MSMQTransaction transaction; str res; queueInfo = new MSMQQueueInfo(); queueInfo.pathName("psp\private$\axapta_queue"); //psp имя локальной машины queue = queueinfo.open(#MQ_SEND_ACCESS, #MQ_DENY_NONE); //тут все валится transaction = dispenser.BeginTransaction(); message = new MSMQMEssage(); message.Label("Label"); message.BodyText("Message!!!"); message.sendInTransaction(queue, transaction); transaction.Commit(); // Close the queue. queue.Close(); } Метод 'Open' в COM-объекте класса 'MSMQ.MSMQQueueInfo' возвратил код ошибки 0xC00E0014 (<неизвестно>), который означает: Указаны недопустимые путь и/или имя очереди. . чего ему не нравится... не пойму |
|
Теги |
ax3.0, msmq |
|
![]() |
||||
Тема | Ответов | |||
Доступ к меню "Работа с документами" | 4 | |||
Совместная работа заказчика и исполнителя в разных или одном слое? | 6 |
Опции темы | Поиск в этой теме |
Опции просмотра | |
|