Hi, i´m trying to create a Hook whit Dot Net and when i run the POS the Hook is fired and i get an error: COM object cannot be created, then i've try to register my DLL using regsvr32 and i get error: xxx.dll was loaded, but the DllRegisterServer entry point was not found, this file can not be registered, some one can help me?
P.D. i've enable in project options "Register for COM "interaporability" and still not working
Didn't find your answer? Ask the community — no account required.
E
Evan Culver
Juan,
Register the assembly with 'regasm', not 'regsvr32'.
- Evan Culver New West Technologies
Juan Acosta wrote:
J
Juan Acosta
Thanks a lot Evan, now i've able to register my DLL, but i still getting error: Attemp to execute COM object 'TenderCheckHook.TenderCheck' failed. Could not create object, whe the hook is fired.
i want to let you know that my DLL's name is TenderCheckHook and the function name is TenderCheck. This Hook is fired just at Tender end event.
Public Class TenderCheck Public o As QSRules.SessionClass Public Function process(ByVal Session As Object) As Boolean
o = Session Dim Trans As Object Dim fCont As Boolean Dim rs1 As ADODB.Recordset Dim TenderDesc$ Dim CustId$
rs1 = o.OpenRecordset("Select * From xSetUp", True) If rs1.BOF = False Then TenderDesc = RTrim(rs1.Fields(0).Value) End If rs1.Close()
rs1 = o.OpenRecordset("Select * From xArXTender Where CustomerId = " & o.Transaction.Customer.ID, True) If rs1.BOF = False Then MsgBox("El cliente tiene pendientes CHP : " & rs1.Fields("TransactionNumber").Value & ", Factura " & rs1.Fields("ReferenceNumber").Value) End If rs1.Close()
fCont = False
For Each Trans In Session.Transaction.Tenders 'MsgBox Trans.Descriptor.Description Descripcion del tipo de pago If Trans.AmountIn 0 And RTrim(Trans.Descriptor.Description) TenderDesc Then MsgBox("Error: no puede cobrar con cheque") fCont = False Exit For Else fCont = True End If Next Trans
process = fCont Exit Function End Function
End Class
Do you have any idea?
"Evan Culver" wrote:
J
Juan Acosta
O
ozzie
A
alia
alia had written this in response to
formatting link
:Can you please elleborate more on '... namespace was uncorrect....'. I amhaving exactly the same issue. But couldn't understand whats wrong withthe namespace as it happend to you. Please explain how did u ractifiedthis error. Thanks Alia
------------------------------------- Juan Acosta@nirgendwo wrote:
Tax and Accounting Software ForumsWeb and RSS access to your favorite newsgroup - microsoft.public.pos - 41496 messages and counting! ##-----------------------------------------------##
J
JerryData
Alia, these problems may not be windows problems. What version of .net are you using? make sure you register your com interop.
Try a very simple thing first, like a message box, so you know your problem is not a programming issue. make sure you return the control of the program to the pos. make sure you are using the pos session object, and not a development or local one. Good luck!
Join the Discussion
Have something to add? Share your thoughts — no account required.
Didn't find your answer?
Ask the community — no account required
Report Content
You are reporting this content to the moderators. They will look at it
ASAP.