?
Solved

*.gif, *.DLL, *.mid, etc. questions.

Posted on 2000-03-04
8
Medium Priority
?
195 Views
Last Modified: 2013-11-20
Hi Everybody!

I have a couple of questions:

1). How does one play a midi file continuously using MFC (VC++ 6.0)
I have the source code for the Windows API SDK but I am finding a little tough to convert the MM_MCINOTIFY message to appropriate message map and message handler entries in MFC.

2). How does one load *.gif and *.jpg files in Windows using MFC. I know that *.bmp files can be easily loaded using the LoadBitmap function. But can someone give me the functions for loading a gif and jpg file in MFC.
Someone pointed to me to
http://web.ukonline.co.uk/Members/julian.smart/code.html
but I cannot find this page.

3). Is there a program in this planet that can list all the functions stored inside a *.DLL file and their prototypes. Also how can I call such a function using MFC.

4). There are 2 ways one can build a project in VC++. One is the Debug version and the other is the Release version. Someone told me that I should do all my development in the Debug version as one can use the macros such as ASSERT(), Debug(), ASSERT_VALID(), etc. in this version. For actual distribution of the software one should recompile in Release version and distribute this program. Is this true?

Thanks in advance.
0
Comment
Question by:jawrani
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 

Expert Comment

by:AidanHolmes
ID: 2583952
On points 3) and 4)

*.DLLs are similar to .EXEs in windows. You need to decipher them by reading the information contained in the .DLL or .EXE header. Go to http://www.wotsit.org/search.asp?section=binary
and look at the PE format. You will then have to write code to read the header inforamtion.

The answer to 4) is yes, but the actual benefit is that you can set breakpoints within your program and step through the execution of your code. Try it by going to any line of your code and setting a breakpoint (F9). Then run in debug mode (F5) and you'll see that the program stops on the line that the breakpoint is on. Also debug mode uses the debug versions of headers and libraries. This means that memory exceptions and other errors in your code can be detected. MFC also tells you about memory leaks.

BTW Too many questions...
0
 
LVL 23

Accepted Solution

by:
chensu earned 300 total points
ID: 2583996
1.
BEGIN_MESSAGE_MAP(CMyWnd, CWnd)
    ON_MESSAGE(MM_MCINOTIFY, OnMMMCINOTIFY)
END_MESSAGE_MAP()


LONG CMyWnd::OnMMMCINOTIFY(UINT wParam, LONG lParam)
{
    //...
    return 0L;
}

2. http://www.anthemion.co.uk/code.htm

3. Dependency Walker (depends.exe)
http://www.dependencywalker.com

But it can only list the function names. There is no way to list the parameters.

4. Yes.
0
 

Author Comment

by:jawrani
ID: 2585182
Thanks chensu.
But for question 2). I want a function from you like LoadGIF (LPTSTR lpszFileName) and LoadJPEG (LPTSTR lpszFileName). I have checked out the site but hey the amount of source code takes me aback. Actually I am developing a screen saver and want to load the *.gif files in the OnTimer (UINT) function. Please Help.

I will check the answers of the rest tomorrow.

Thanks chensu.
0
Survive A High-Traffic Event with Percona

Your application or website rely on your database to deliver information about products and services to your customers. You can’t afford to have your database lose performance, lose availability or become unresponsive – even for just a few minutes.

 

Author Comment

by:jawrani
ID: 2585195
Thanks chensu.
But for question 2). I want a function from you like LoadGIF (LPTSTR lpszFileName) and LoadJPEG (LPTSTR lpszFileName). I have checked out the site but hey the amount of source code takes me aback. Actually I am developing a screen saver and want to load the *.gif files in the OnTimer (UINT) function. Please Help.

I will check the answers of the rest tomorrow.

Thanks chensu.
0
 

Author Comment

by:jawrani
ID: 2585204
Thanks chensu.
But for question 2). I want a function from you like LoadGIF (LPTSTR lpszFileName) and LoadJPEG (LPTSTR lpszFileName). I have checked out the site but hey the amount of source code takes me aback. Actually I am developing a screen saver and want to load the *.gif files in the OnTimer (UINT) function. Please Help.

I will check the answers of the rest tomorrow.

Thanks chensu.
0
 
LVL 23

Expert Comment

by:chensu
ID: 2586486
2. That is a library and it comes with samples. Look into it. It is not hard to use.
0
 

Author Comment

by:jawrani
ID: 2592747
Thanks Chensu.
You get the credit.

Could You please tell me how to go about making a registry cleaner. I mean how to check for Orphan entries in the registry and the broken links therein.

Any links/sites/source code will be welcomed.

Thanks.

0
 
LVL 23

Expert Comment

by:chensu
ID: 2592896
According to EE's policy, you may ask one question per question. Please post a new question. I will answer it.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question