Quantcast
Channel: WinDev Forum
Viewing all articles
Browse latest Browse all 1914

Working with DotNetDelegate

$
0
0
Hi,

I'm working with a Magtek DynaPro Keypad device to encrypt Credit Card entries for a client. I've been successful importing the MagTek .NET assembly and using it to open and initialize the device and accept card number entry

Where I'm stuck now is how to write the code to use DotNetDelegate to get the result back from the device.

My calling code to the device looks like this.




// declare object

clMagtek is object MTPPSCRA

//open device

sDevice is UNICODE string
nOpen is int=clMagtek.openDevice(sDevice)

// request manual card entry
nStatus is int
clMagtek.requestManualCardData(60,1,31010003,nStatus)




From what I gather I now need to use a "DotNetDelegate" event to get the result back from the device. Here is the section from the device docs.

4.11 OnCardRequestCompleteEvent

Return event for requestCard.

public delegate void OnCardRequestCompleteEvent(String lpData);

Parameter : Description

lpData : A response string for the requestCard function.


I've looked at the Windev docs I'm really not clear on how to implement the callback function and several hours of mucking around hasn't seemed to get me any closer.

Can anyone help with this?

Thanks!

steve

Viewing all articles
Browse latest Browse all 1914

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>