|
Sorry, i got your question wrong.
"When death smiles at you, only thing you can do is smile back at it" - Russel Crowe (Gladiator)
|
|
|
|
|
Hi,
I have a classic Win32 DLL (including it's sources), which is imported into project implicitely.
Can I somehow control the path from where the DLL is loaded, while leaving the DLL import implicit? (i.e. not use the default LoadLibrary strategy)
Flirt harder, I'm a Coder
mlog || Agile Programming | doxygen
|
|
|
|
|
humm,Well i am not giving you a solution just a thought though.
you mean to say that if there are 2 different versions of the same dll in the path then you want to control which dll to load, rite???
If I got that rite, then i guess that exactly is one of the problem why COM evolved.
"When death smiles at you, only thing you can do is smile back at it" - Russel Crowe (Gladiator)
|
|
|
|
|
Yup I know... But the interface is *very* Win32, and I don't want to convert it to COM. I was thinking of the same way, more or less.
Actually, the Win32 way would be acceptable for the release, but I'm looking for a solution during debug...
Flirt harder, I'm a Coder
mlog || Agile Programming | doxygen
|
|
|
|
|
humm, Seems like there is no easy workaround otherwize you would have already got it.
I understand ur prob, during development this kinda prob arises. How i have done is that the dll should not be in any path instead it's binary output should be in the same directory of the output path of the host binary file(I assume the host is also developed by you).
This way if the host binary is diff, say debug or release, then appropriate dll will be loaded.
Well i dont know the sol that you are asking for, but i guess its just a precaution that need to be taken to avoid versioning problem,
I also time n again search for the dlls (development ones) in the root project folder and delete them.
"When death smiles at you, only thing you can do is smile back at it" - Russel Crowe (Gladiator)
|
|
|
|
|
i have created a dialog windows application using the app wizard.
it has a few other sub dialogs which are created from code behind file menu bar.
Im looking for a method to get access the main dialog windows data from the other sub dialogs.
im sure their is any easy way to get a pointer to the data ?
|
|
|
|
|
if the data is in the main dialog class, you need to pass a pointer of that dialog to the sub-dialogs.
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|
|
Hello,
GetParent() returns the main dialog pointer.
CWnd* GetParent( ) const;
Regards,
Hadi
|
|
|
|
|
I would like to create several rectangles overlapping each other but having a transparent look. How can I achieve this by not using bitmaps but regular GDI functions, such as Rectangle(), etc.
Thanks
|
|
|
|
|
Might help: "An application sets the foreground mix mode by using the SetROP2 function and retrieves the current mode by using the GetROP2 function."
These are only for binary raster ops though. Not sure how you would control the mix amount with a setting for alpha blend amount.
|
|
|
|
|
I develop an application (electrical train) where I want to add some sound: a bakground music and some noise depending on my application events.
I used SndPlaySound but it just allow to play .wav file and only one and the same time.
I need to play .mp3 file and add some .wav noises to be more funny
Can someone indicate me which MFC function to use with some exemples.
Thanks a lot....
NKH
|
|
|
|
|
Hello,
The best way for playing .MP3 and .WMA files is DirectShow
There's many libraries on the internet that could do it too.
I'm sure that you can find some samples about playing mp3 files from CP site. ( i saw some good audio players and etc. )
hmm, MCI is another way
Regards,
Hadi
|
|
|
|
|
Hi,
I am writing an application, which does some monitoring work. Here I have to include two buttons and a list box. Now I have to trap the WM_KEYDOWN/ WM_KEYUP messages and scan the contents of the list box. Can provide me some help in this issue?
|
|
|
|
|
Using ClassWizard, select the name of your listbox class in the Class name: combobox. In the Messages list, select WM_KEYDOWN . Click the Add Function button. Do the same thing for the WM_KEYUP message. Populate the message handlers as you need.
A rich person is not the one who has the most, but the one that needs the least.
|
|
|
|
|
Hi guys
I developed an application in MDI,
I want to know .. i open an new document and close it.. the memory for that document be released...i checked in task manager , it dosent show any release of memory..how shld i find out or wat functions shld i call to release the memory for the document
Thanks
krithika
|
|
|
|
|
TaskManager may not show any change; the memory may be in a heap ready for your app to reuse, but the heap itself has not been shrunk.
The framework will use DeleteContents(), which should clear any member variables in your document.
If you exit, then a debug build will generally show you common memory leaks if you're running under a debugger.
Steve S
|
|
|
|
|
|
Hi everyone !
Is there any way to wait for a callback function like the HookProcs ?
Thanks in advance,
André Schmidt
|
|
|
|
|
Huh?
What do you mean by 'wait for a callback function'?
Do you want an indication when one is called?
(If so, the function could signal an event)
Do you want to wait until a callback has returned?
(doesn't this happen anyway?)
Steve S
|
|
|
|
|
Hi,
is there a simple way to set a PropSheet's background color?
and, how can you set that for a CTabCtrl???
thx
|
|
|
|
|
Hi!
With CreateFromFile() I am able to open an excel file in my ole
container application.
I want to embed excel sheet in my container applicatio and want to
display contents of a file, but i dont want to use CreateFromFile(), I
just want to pass raw data as input.
Which function shall I use,CreateFromClipboard() or CreateFromData().
I am running in Win2k and have office2k.
Thanks
Anshu
|
|
|
|
|
Hello,
I am a beginner in Embedded VC++ programming and am confronted with a problem :
I have a desktop connected to a PDA.I have to write a program to send data from the desktop which would be read and displayed by the PDA.Any suggestions on how to proceed with this is most welcome.
Thanks,
Deepa.
|
|
|
|
|
On the platform end (Windows), the software opens a port, sets the port settings, writes data and closes the port. On the receiving end (PDA), the program must first open the port, then create a listener for incoming data, and when the listener fires an event, read data from the port and close the connection.
Here is a lengthy article digging into the aspects of serial communication quite in-depth. It might be helpful to you: http://www.codeproject.com/system/serial_com.asp[^]
Here is a link to MSDN dictating the Serial Communication on WinCE[^]. I don't know what OS your PDA uses, but perhaps reading it will be helpful.
-Antti Keskinen
----------------------------------------------
The definition of impossible is strictly dependant
on what we think is possible.
|
|
|
|
|
Hello Antti,
Thank you for your kind response.My PDA uses Win CE.I have written a program in EVC++ to write a few characters to the COM1 port.Now I have no idea how to implement the read program in the PDA so that it can read the data being sent.
Thanks
Deepa.
|
|
|
|
|
Just follow the implementation guide from Microsoft for Windows CE to develop the application. You must have the port settings made similar. If you readed the first article I posted, a data structure is mentioned there with which you can set the port settings in the Windows end. See the Microsoft WinCE documentation for a respective setting on the PDA end.
I think versions of WinCE sport some type of MFC support, and thus you can use much of the same code to implement port reading on the PDA end. For this purpose, you would need to consult the PDA documentation and/or files to see what version of MFC it supports.
The most effective way is to use the Microsoft-provided WinCE emulator. This allows you to develop and test code on an emulator before sending it to the actual device. I think eVC++ supports on-device debugging through a serial connection. This is not very viable in your case, as you need the serial connection yourself. So use the emulator.
For an example, create the WinCE build, run it in the emulator, then start the Windows-end program, write data into the port and attempt to read it through the emulator. For an extremely effective method, if your computer supports two COM ports, you can write to the first using the Windows-program, then read from the second using the emulator-driven build. Just get a cross-connected serial cable (or build one yourself) to inter-connect the two ports.
Also, you should post this question into the Embedded / Mobile area, as most of the users who develop WinCE software tend to hang around there, and thus you might get more knowledgeable answers.
-Antti Keskinen
----------------------------------------------
The definition of impossible is strictly dependant
on what we think is possible.
|
|
|
|