Click here to Skip to main content
15,919,028 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Tell me the difference :) Pin
Remi Morin17-Sep-01 6:02
Remi Morin17-Sep-01 6:02 
GeneralCorrection: Tell me the difference :) Pin
17-Sep-01 22:28
suss17-Sep-01 22:28 
GeneralRe: Tell me the difference :) Pin
Alvaro Mendez18-Sep-01 10:42
Alvaro Mendez18-Sep-01 10:42 
GeneralAbsolute bloody ADO hell Pin
Christian Graus17-Sep-01 3:55
protectorChristian Graus17-Sep-01 3:55 
GeneralRe: Absolute bloody ADO hell Pin
Michael P Butler17-Sep-01 4:01
Michael P Butler17-Sep-01 4:01 
GeneralRe: Absolute bloody ADO hell Pin
Christian Graus17-Sep-01 4:06
protectorChristian Graus17-Sep-01 4:06 
GeneralRe: Absolute bloody ADO hell Pin
Michael P Butler17-Sep-01 4:27
Michael P Butler17-Sep-01 4:27 
GeneralRe: Absolute bloody ADO hell Pin
Christian Graus17-Sep-01 4:27
protectorChristian Graus17-Sep-01 4:27 
I've solved it, thanks. I read my recordset in like this:

	_RecordsetPtr records = NULL;
	 records.CreateInstance(__uuidof(Recordset));

	try
	{
		records->CursorType = adOpenStatic;
		records->CursorLocation = adUseClient;
		records->Open("SELECT * FROM FileDatabase",
		_variant_t((IDispatch*)m_Connection, true), adOpenKeyset, adLockOptimistic, 
		adCmdUnknown);
	}
	catch(...)//_com_error & e)
	{
//		MessageBox(NULL, e.ErrorMessage(), "", 0);
	}


and if the database file in empty it crashes big time. Do you know why that might be ? Anyhow, as a result the first record is a dummy record. I needed to reread some ADO stuff to get clear in my mind what I was manipulating, then I checked the VARIANT coming back from ->Value and found it was VT_NULL, because when I added those four fields, I didn't add dummy values for the dummy record.

I'd love your insight on my empty DB problem though, and on accessing values by position, if you don't mind.

Thanks for the help.


Christian

As I learn the innermost secrets of the around me, they reward me in many ways to keep quiet.

Men with pierced ears are better prepared for marriage. They've experienced pain and bought Jewellery.
GeneralRe: Absolute bloody ADO hell Pin
Michael P Butler17-Sep-01 4:35
Michael P Butler17-Sep-01 4:35 
GeneralRe: Absolute bloody ADO hell Pin
Jeremy Pullicino17-Sep-01 5:29
Jeremy Pullicino17-Sep-01 5:29 
GeneralRe: Absolute bloody ADO hell Pin
Christian Graus17-Sep-01 13:00
protectorChristian Graus17-Sep-01 13:00 
GeneralAbsolute bloody ATL hell Pin
Christian Graus17-Sep-01 2:12
protectorChristian Graus17-Sep-01 2:12 
GeneralRe: Absolute bloody ATL hell Pin
Michael P Butler17-Sep-01 2:35
Michael P Butler17-Sep-01 2:35 
GeneralRe: Absolute bloody ATL hell Pin
Christian Graus17-Sep-01 2:51
protectorChristian Graus17-Sep-01 2:51 
GeneralRe: Absolute bloody ATL hell Pin
Michael P Butler17-Sep-01 3:02
Michael P Butler17-Sep-01 3:02 
GeneralRe: Absolute bloody ATL hell Pin
Christian Graus17-Sep-01 3:10
protectorChristian Graus17-Sep-01 3:10 
GeneralRe: Absolute bloody ATL hell Pin
Michael P Butler17-Sep-01 3:15
Michael P Butler17-Sep-01 3:15 
GeneralRe: Absolute bloody ATL hell Pin
Christian Graus17-Sep-01 3:30
protectorChristian Graus17-Sep-01 3:30 
GeneralHandling Button's Events Pin
MAAK17-Sep-01 1:26
MAAK17-Sep-01 1:26 
GeneralRe: Handling Button's Events Pin
Michael P Butler17-Sep-01 2:01
Michael P Butler17-Sep-01 2:01 
QuestionHow do I find out what workgroup/domain a host is in? Pin
Paul Vickery17-Sep-01 0:37
professionalPaul Vickery17-Sep-01 0:37 
AnswerRe: How do I find out what workgroup/domain a host is in? Pin
Michael P Butler17-Sep-01 2:07
Michael P Butler17-Sep-01 2:07 
GeneralRe: How do I find out what workgroup/domain a host is in? Pin
Paul Vickery17-Sep-01 3:20
professionalPaul Vickery17-Sep-01 3:20 
GeneralTicks in menus Pin
Nick Armstrong17-Sep-01 0:30
Nick Armstrong17-Sep-01 0:30 
GeneralRe: Ticks in menus Pin
Rashid Thadha17-Sep-01 0:52
Rashid Thadha17-Sep-01 0:52 

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.