|
|
hmm...beats me. Will it stop on a breakpoint in the EXE module? If so, can you step into a DLL from there?
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I guess I could've tried that, but I decided to do a rebuild, and see if it was some kind of environment issue. The same DLLs are actually placed in multiple locations (copied over, but not sure what kind of script manages it), and you get references from one location to another, so starting from scratch may be the best way.
Thanks for helping.
I'll post an update later to see if I figure anything out.
|
|
|
|
|
Well, I never really finally understood what was wrong, but by setting the DLL project as the startup application and launching it with the executable specified, rather than attaching to process, something worked (by the way, I didn't figure this out -- I had a bit of help on my end).
|
|
|
|
|
2nd parameter of SQLConnect() method is the DSN name.
In my application i m using DSN-less connection by specifying the path of data.
So now whst do i pass as the 2nd parameter?
Alternatively: I tried using SQLConfigDataSource():
SQLConfigDataSource(NULL,ODBC_ADD_DSN, "SQL Server (*.mdf)",
"DSN=New SQL Data Source\0");
BUt it returns 'false'
Am i passing it the right data??
-- modified at 0:58 Wednesday 22nd August, 2007
|
|
|
|
|
yashveer wrote: 2nd parameter of SQLExecute() method is the DSN name.
Last time I checked, SQLExecute() had only one parameter, the statement handle.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi,
what are .ppm files.How can we open these files.If they are the type of image format then how can i open them.
Regards,
|
|
|
|
|
|
See .PPM File Extension[^] this site is a very good site about extension files you can get perfect info of extension files.
|
|
|
|
|
i mant to extract html source code of any web page and store it in CString.
Which Interface to use.
Any GURU Pls help me with the code.
thanks in advance.
Dhiraj
Dhiraj Kumar Saini
|
|
|
|
|
CInternetSession objInternetsession;
int nLength = 100; // Can be changed.
char* pchData = new char[nLength];
CHttpFile* pHttpFile = (CHttpFile*) objInternetsession.OpenURL(m_csUrl);
long x = pHttpFile->GetLength();
pHttpFile->Read(pchData, x);
CString csData = pchData;
I hope this will work for you.
Thanks,
Anand.
|
|
|
|
|
In above example, m_csUrl is a CSting object containing the URL.
Thanks,
Anand.
|
|
|
|
|
|
My problem is that whenever i open a web page i wanna extract the source code of the web page and display it in a MessageBox.
for eg if i visit www.yahoo.com the entire source code of yahoo.com should be extracted and displayed through a message box.
Pls help me out any one of the gurus.
Thanks in advance
Dhiraj Kumar
dhiraj kumar saini
|
|
|
|
|
Displaying it in Notepad is not sufficient?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Dhiraj kumar Saini wrote: entire source code of yahoo.com
Yikes, how big is your monitor?
More seriously, you can make your own dialog box, and then add an html control to it, and ask it to display (eg) www.yahoo.com.
But displaying html using the MessageBox command? Tough. You'll have to do a bunch of work yourself.
Iain.
|
|
|
|
|
Hi, I need to be able to create a CString that is always 15 characters long. So I just want to have say the filename and then pad the rest of the 15 characters with spaces, anyone know of an easy way of doing this? Currently I'm just using strlen and a loop, but I think there probably is a better way.
Thanks
Simon
|
|
|
|
|
CString s;
s.Format("%-15s", "Simon");
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
David you are such a great help.
Thank you!
|
|
|
|
|
|
Programm3r wrote: ...when I perform the function GetRowsAffected() the return code is -1, stating that something went wrong. Not sure what
How about stepping into the Execute() method to find out why?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
I would love to, but I keep getting a 'External Exception C000000008' Error Window as I perform the pdb.DriverConnect() function ....
Regards,
The only programmers that are better that C programmers are those who code in 1's and 0's
Programm3r
My Blog: ^_^
|
|
|
|
|
So step into that method to find out why.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
The second time I call this function to connect to another database (I created another instance), I recieve the exception message.
ret = SQLDriverConnect(m_hDbc,
hWnd,
(SQLCHAR*)szConnStr,
SQL_NTS,
(SQLCHAR*)szConnStrOut,
sizeof(szConnStrOut),
&pcbConnStrOut,
(SQLUSMALLINT)drvConn);
Regards,
The only programmers that are better that C programmers are those who code in 1's and 0's
Programm3r
My Blog: ^_^
|
|
|
|
|
Channeling David Crow...
"So step into that function..."
Do you really mean the exception message is "ret = SQLDriverConnnect... etc"?
If not, it would help if you actually say what exception you're getting. Are all the pointers you supply the function fully valid? ascii instead of unicode (or vice versa), szConnStrOut at least as big as it need to be? is pcbConnStrOut needing to be set to something going in as well as out?
Etc.
If you look at the SQLDriverConnect function help page, does it say it raises an exception if it can't connect? If so, wrap it with TRY / CATCH etc, and swear at the user for picking a wrong database. And so on....
Nobody else is going to be able to help with that sadly, as it will depend on a big lump of your code.
What you can do is to make a small test program, with those parameters hard coded and carefully validated, then call the function. If *that* works, then you have a bug in your main program and are feeding the function junk.
Iain.
(ps, I have little idea about SQL - this is generic programming / debugging advice)
|
|
|
|