1

I am using C# to implement JKFinger SDK into our office project and I am new to C#. There are two methods in SDK, PrintImageAt() which is drawing image into PictureBox And GetFingerImage() get the last captured image by device in bmp format.

Graphics g = pictureBox1.CreateGraphics();
int dc = g.GetHdc().ToInt32();
axZKFPEngX1.PrintImageAt(dc, 0, 0, axZKFPEngX1.ImageWidth, axZKFPEngX1.ImageHeight);
object obj = null;
axZKFPEngX1.GetFingerImage(ref obj);

Now I want to store the captured image into database. The PictureBox is displaying the images but not initializing with it. For getting image from PictureBox is returning null. And for GetFingerPrint(ref obj) is returning an object but can't be converted to Bitmap. I want to know how to get that image.

1 Answer 1

1

GetFingerPrint(ref obj) Is returning System.Byte[] Object.

axZKFPEngX1.GetFingerImage(ref obj);
byte[] data = (byte[])obj;
MemoryStream ms = new MemoryStream(data);
Image image = Image.FromStream(ms);
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.