|
Hey Joaquín,
If i did go with some sort of connection pooling module how would one pass an ADO connection across threads. In MFC its often tough to pass objects across threads. Would I somehow allocate the connection on the heap and pass a pointer to it?
|
|
|
|
|
There's no problem at all with passing pointers to memory around threads within the same process. However, in my proposed scheme this is not necessary, as each thread can maintain its own DB connection. The improvement in efficiency results from the threads not closing its connections, but instead reusing it each time they're re-activated. As an added benefit, the architecture is simple with respect to concurrency issues (essentially, threads do not share any resource with each other).
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Hello!
I'm currently working on a big project which uses a Microsoft Access database as the backend for storing data. This application is possibly going to be distributed commercially, so I need to know what is my best bet on what kind of database to use. With Access right now I can manipulate the database with a good level of control and ease of coding, but I'm sort of worried about the problems I might have distributing it, since people might not have Access drivers installed on their computers, or it might be painfully slow on slower computers. One of my biggest concerns is the speed of the database for a LARGE dataset, for instance north of 20,000 rows in one table, around 1,000 for two other tables.
Can anyone point me to a nice comparison chart or lay down some information for different databases as far as concerns the speed, the overhead, the ease of installation on a user's machine? I would be very appreciative!
Also, does anyone know a good place to start if I'm interested in creating a Visual C++ application which uses the MySQL database?
Thanks in advance!
Sincerely,
Alexander Wiseman
Est melior esse quam videri
It is better to be than to seem
|
|
|
|
|
|
I want to paint something outside of the client rect, but how to get that area?
Who can help me out? I would like to know if there is a function that returns a CRect.
Thanks
|
|
|
|
|
GetWindowRect returns that. Note that returned rect is in screen coordinates.
Tomasz Sowinski -- http://www.shooltz.com
|
|
|
|
|
|
How can I change the size of a Title Bar? I tried changing the CREATESTRUCT of the WM_NCCREATE message, but that didn't work...
Thanks in advance
|
|
|
|
|
|
"The WM_NCCALCSIZE message is sent when the size and position of a window's client area must be calculated. By processing this message, an application can control the content of the window's client area when the size or position of the window changes." - MSDN
I know it must be possible, as the size of the Title Bar changes when the dialog is a 'Tool window'
Can somebody please help me out? Some source code would be greatly appreciated.
|
|
|
|
|
So what's the problem? Capture the message and return the client area small or big enough for given titlebar size.
Tomasz Sowinski -- http://www.shooltz.com
|
|
|
|
|
See this article for funky nonclient area drawing tricks.
/ravi
"There is always one more bug..."
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
Thanks! That might be what I'm looking for.
|
|
|
|
|
i have a 1 to many dialog
i show one record of many and have a list showing all.
i would like have the list hilight the current record while either browsing or editting the current one.
So my actual question is:
Is there a way to hilight a row on a listcontrol without having focus?
|
|
|
|
|
|
i have tried that but the row is only hilighted with the control has focus.
as soon as focus is lost the hilight also goes away.
would be greatful for anyother suggestions. thank you.
|
|
|
|
|
Do you have 'Show selection always' option set in the dialog editor?
If you're creating list control dynamically, use LVS_SHOWSELALWAYS style.
Tomasz Sowinski -- http://www.shooltz.com
|
|
|
|
|
that is exactly the problem. thank you very much.
|
|
|
|
|
Hi ,
I am trying to create an editor similar to MS VisualStudio's
Resource Editor for Dialog.
In this I need to create a Label, which would contain Text
and be dragged around and also be resized.
Can some one tell me how it can be done.
Thanks,
Sansky
|
|
|
|
|
Howdy,
I think you would need to override several mouse functions in your Label class to do the following:
OnLButtonDown: Track when the user clicks and if they have the left button down so that you can know what to do when they move the mouse
OnLButtonUp: Again, use this to remember the mouse button state
OnMouseMove: Inside here test to find out if the mouse button is down and if so, use MoveWindow to move your window to the same coordinates as the mouse is moving to
I think that should do it, but this is just a guess. Hope it gives you a good direction to start looking...
Dave
|
|
|
|
|
Hi,
Thanks, What I need is, how do I create, display ,move and
resize Label
Also I might need to display the Label in the CView, as I
am not sure if I could drag and resize objects in CDialog.
Any suggestions
Regards,
Sansky
|
|
|
|
|
Is there a way to use something like the Internet Explorer "Save as" method in my own programs? I want to save a webpage including the images...
Is there a method / macro to use or do i have to do it all manually ( extracting the tags etc..)?
Thanks for your help...
|
|
|
|
|
Hello,
My application need during execution
to dinamically load a driver (.sys).
How can I do this programatically?
Also, how can I use Visual C++ to
compile a driver? I search in MSDN
and fount at visual c++ linker options
"Use the /DRIVER linker option to build a Windows NT kernel mode driver. ". But how should I use this? I can't figure myself.
Thanks
|
|
|
|
|
Don Miguel wrote:
Also, how can I use Visual C++ to
compile a driver?
You'll need a DDK. DDK is the acronym for Driver Development Kit. http://www.microsoft.com/ddk/ has the details. AFAIR, DDK for Win2000 is even available as a free download.
Tomasz Sowinski -- http://www.shooltz.com
|
|
|
|
|
You can set up a driver project in VC, though its a good idea to look at what build.exe does first. For the linker, the /subsystem:NATIVE,400 /driver settings will be needed. Compiler switches will vary based on language (c or c++). The NTDDK libs (int64.lib ntoskrnl.lib hal.lib) want _stdcall calling convention.
On NT, you can dynamically load a driver using the service control manager, calling CreateService with SERVICE_KERNEL_DRIVER as the service type, then StartService . This doesn't work on Win9x though - not sure if its possible without user interaction (can u say PnP?).
|
|
|
|