[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

MFC CLongBinary

Posted on 1998-12-17
1
Medium Priority
?
380 Views
Last Modified: 2013-11-20
I'm using CRecordset and CLongBinary to insert image into SQLServer6.5 database.  I did call SetFieldDirty() after I called AddNew(), then I read image out of a image file into the buffer I allocated.  The data pointer in the CLongBinary object points to the data buffer.  But after update() call, the image field still seems to be null.  No exception was thrown.  Everything seems to be ok except when I look at the table, the field is null.  Why?
0
Comment
Question by:accord
1 Comment
 
LVL 4

Accepted Solution

by:
piano_boxer earned 200 total points
ID: 1326372
Try also calling SetFieldNull(&m_nMyClassMember, FALSE) after the SetFieldDirty(&m_nMyClassMember, TRUE) call.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question