Click here to Skip to main content
16,004,887 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: problem with dialog procedure Pin
David Crow9-Jun-06 5:28
David Crow9-Jun-06 5:28 
GeneralRe: problem with dialog procedure Pin
fury 849-Jun-06 10:41
fury 849-Jun-06 10:41 
GeneralRe: problem with dialog procedure Pin
David Crow9-Jun-06 10:46
David Crow9-Jun-06 10:46 
AnswerRe: problem with dialog procedure Pin
Viorel.9-Jun-06 5:38
Viorel.9-Jun-06 5:38 
GeneralRe: problem with dialog procedure Pin
fury 849-Jun-06 10:48
fury 849-Jun-06 10:48 
Questioncontrol Pin
yogendra kaushik9-Jun-06 4:22
yogendra kaushik9-Jun-06 4:22 
AnswerRe: control Pin
David Crow9-Jun-06 4:31
David Crow9-Jun-06 4:31 
Questionproblem in inserting image into the database Pin
maharaja pandian9-Jun-06 4:14
maharaja pandian9-Jun-06 4:14 
hi,
i develop one application in VC++-MFC 6.0 ,
this application is responsible for inserting image into the database (oracle)-ODBC.
but when i try to insert a image file , it through a error like
"Data type conversion error."
////////////////////////////////////////////////////////////////////////
CDaoDatabse db;
CDaoRecordset recset(&db);
void CDBODBC::InsertintoDB();
{
CByteArray BlobFile;
BlobFile.RemoveAll(); // I clear the Array
CFile aFile("image.jpg",CFile::modeRead);
BlobFile.SetSize(aFile.GetLength());
aFile.Read(BlobFile.GetData(),aFile.GetLength());
aFile.Close();
COleVariant aVar(BlobFile);
CString Sql = "SELECT * FROM sample3";
db.Open("abc",FALSE,FALSE,"ODBC;UID=abcWD=abc;DSN=abc;");
recset.Open(AFX_DAO_USE_DEFAULT_TYPE,Sql,dbAppendOnly);
// bool b=recset.CanUpdate();
recset.AddNew();

recset.SetFieldValue("[num]","6"); //varchar field
recset.SetFieldValue("[photo]",aVar); //BLOB field -image field
recset.Update();
recset.Close();
db.Close();


}
/////////////////////////////////////
it works for Access database ..
but i got error in oracle...
"Data type conversion error."

Try again and again,
At last you will say
I don't know the meaning for impossible.,.

AnswerRe: problem in inserting image into the database Pin
David Crow9-Jun-06 4:36
David Crow9-Jun-06 4:36 
GeneralRe: problem in inserting image into the database Pin
maharaja pandian9-Jun-06 20:26
maharaja pandian9-Jun-06 20:26 
AnswerRe: problem in inserting image into the database Pin
Viorel.9-Jun-06 4:40
Viorel.9-Jun-06 4:40 
GeneralRe: problem in inserting image into the database Pin
maharaja pandian9-Jun-06 20:25
maharaja pandian9-Jun-06 20:25 
QuestionProblem Writing bitmap info File Pin
Reji_Kumar9-Jun-06 4:08
Reji_Kumar9-Jun-06 4:08 
AnswerRe: Problem Writing bitmap info File Pin
Viorel.9-Jun-06 4:31
Viorel.9-Jun-06 4:31 
AnswerRe: Problem Writing bitmap info File Pin
Chris Losinger9-Jun-06 5:27
professionalChris Losinger9-Jun-06 5:27 
QuestionAdding static control to childvew Pin
rajeev829-Jun-06 3:35
rajeev829-Jun-06 3:35 
AnswerRe: Adding static control to childvew Pin
Viorel.9-Jun-06 3:53
Viorel.9-Jun-06 3:53 
GeneralRe: Adding static control to childvew [modified] Pin
rajeev829-Jun-06 3:55
rajeev829-Jun-06 3:55 
QuestionRe: Adding static control to childvew [modified] Pin
Viorel.9-Jun-06 4:05
Viorel.9-Jun-06 4:05 
GeneralRe: Adding static control to childvew [modified] Pin
Cedric Moonen9-Jun-06 4:06
Cedric Moonen9-Jun-06 4:06 
GeneralRe: Adding static control to childvew Pin
rajeev829-Jun-06 18:19
rajeev829-Jun-06 18:19 
GeneralRe: Adding static control to childvew Pin
Cedric Moonen9-Jun-06 22:17
Cedric Moonen9-Jun-06 22:17 
QuestionOpen Dialog "Filter for file names" Pin
Nitefall20609-Jun-06 3:21
Nitefall20609-Jun-06 3:21 
AnswerRe: Open Dialog "Filter for file names" Pin
David Crow9-Jun-06 3:46
David Crow9-Jun-06 3:46 
GeneralRe: Open Dialog "Filter for file names" Pin
Nitefall20609-Jun-06 4:41
Nitefall20609-Jun-06 4:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.