|
What do you mean?
Where you get your menu text and menu ID does not matter: CMenu allows you to add arbitrary text and numbers.
You may as well load it from registry entries.
If you want to change a menu from a menu bar, you would need to handle WM_INITMENU or override CWnd::OnInitMenu .
There you can modify the menu - to the point of assembling a completely different menu.
"We trained hard, but it seemed that every time we were beginning to form up into teams we would be reorganised. I was to learn later in life that we tend to meet any new situation by reorganising: and a wonderful method it can be for creating the illusion of progress, while producing confusion, inefficiency and demoralisation."
-- Caius Petronius, Roman Consul, 66 A.D.
|
|
|
|
|
hi,
can anybody tell me what this function is going to return,
WINGDIAPI BOOL WINAPI BitBlt( IN HDC, IN int, IN int, IN int, IN int, IN HDC, IN int, IN int, IN DWORD);
Thanks in advance
Siddharth
|
|
|
|
|
it returns a BOOL only.
what you see around are the calling convention (find the definition of WINAPI - it's certainly like __cdecl) and see also how's defined WINGDIAPI
|
|
|
|
|
thanks
|
|
|
|
|
Hi all,
This might be a stupid question, but does VS 2005 (VC++) have a media player component?
Many thanx,
Regards
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
What you want exactly ?
Is it Windows Media player activeX control ?
|
|
|
|
|
I really thought it was a simple question, but ok ... I just wanted to know if VS 2005 had a Media Player form component that can be added to the form, thats all.
Thanx again,
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
|
Programm3r wrote: I really thought it was a simple question, but ok ...
Not seen much of forms. Obviously, looked in to MFC context.
|
|
|
|
|
My bad ...
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
In Visual Studio, open the Toolbox.
If Windows Media Player does not appear on the Components tab of the Toolbox, do the following:
Right-click within the Toolbox, and then select Add/Remove Items. This opens the Customize Toolbox dialog box.
On the COM Components tab, select Windows Media Player.
If Windows Media Player does not appear in the list, click Browse, and then open Wmp.dll, which should be in the Windows\System32 folder.
Click OK. The Windows Media Player control will be placed on the current Toolbox tab.
You can now select Windows Media Player in the Toolbox and add it
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r
|
|
|
|
|
I have a question do you want to play movie files
|
|
|
|
|
Hi.
I am trying to display a graph in a dialog with data input from a file which i have put it in an array. How do i display the array with its data as the y-axis? This is what I have gotten so far and I am stuck here.
<br />
void CCTestDlg::OnOpenfile() <br />
{<br />
ifstream file;<br />
short data[10240];<br />
int iI;<br />
<br />
static char szFilter[] = "Binary files (*.bin)|*.bin|All files (*.*)|*.*||";<br />
<br />
DWORD dwFlags = OFN_HIDEREADONLY | OFN_FILEMUSTEXIST | OFN_PATHMUSTEXIST;<br />
<br />
CFileDialog m_ldFile(TRUE, ".bin", NULL, dwFlags, szFilter);<br />
<br />
if (m_ldFile.DoModal() == IDOK)<br />
{<br />
m_filePath = m_ldFile.GetPathName();<br />
<br />
file.open (m_filePath, ios::in|ios::binary);<br />
<br />
if (file.is_open())<br />
{<br />
for (iI = 0; iI < 10240; iI++)<br />
{<br />
data[iI] = file.get();<br />
}<br />
<br />
file.close();<br />
}<br />
}<br />
}<br />
If in SDI, there is a OnDraw() function but how do I do it in a dialog?
Thanks in advance.
|
|
|
|
|
|
ReturnRain wrote: If in SDI, there is a OnDraw() function but how do I do it in a dialog?
Does this[^] help?
Short story: Define a control for that!
Don't do it on the dialog. Your control might even have no border, so it looks like the drawing takes place on the dialog.
"We trained hard, but it seemed that every time we were beginning to form up into teams we would be reorganised. I was to learn later in life that we tend to meet any new situation by reorganising: and a wonderful method it can be for creating the illusion of progress, while producing confusion, inefficiency and demoralisation."
-- Caius Petronius, Roman Consul, 66 A.D.
|
|
|
|
|
Hello.
I tried to follow the link above (the one that jhwurmbach gave) and define a picture control. But I just get lost somewhere. I dont know if I am doing it right.
I placed the picture control on the dialog and change its ID and type to rectangle. Then it stated to add #include SpectrumAnalyzer.h to dialog header and to add member variable to dialog. Meaning I have to created SpectrumAnalyzer.h first? What should I do next?
I tried to find in the internet on picture control with rectangle as its type but I just couldn't find it. Is there any link that will teach me step by step on picture control?
Thanks again in advance.
|
|
|
|
|
ReturnRain wrote: add member variable to dialog.
So, you have added the include-line at the top of your dialog class-header file (but below the #include "stdafx.h ").
Now you add the lines given in the SpectrumAnalyser-Article
public:
CSpectrumAnalyzer m_SpectrumAnalyzer_Ctrl; to your dialog header.
The Demo-project from the SpectrumAnalyzer article shows what to do in its CSpectrumAnalyzerDemoDlg -class (the two files SpectrumAnalyzerDemoDlg.h and SpectrumAnalyzerDemoDlg.cpp )
You probably want the Spectrum Analyzer to be shown right from the start, so the creation code (in the demo found in the OnScanBtn() button click handler) needs to be moved to the OnCreate -function of your dialog (add it using the Visual-C++ code wizard!).
ReturnRain wrote: s there any link that will teach me step by step on picture control?
You won't get more than the Article I linked shows you. Basic C++ and MFC knowledge is required beforehand.
Failure is not an option - it's built right in.
|
|
|
|
|
How can i get list of the names of all devices attached with current system in VC++?
|
|
|
|
|
Certainly not by repeating the question, and most positivley not after being provided with 5 links. Stop waiting for somebody to give you the answer and go do some research.
|
|
|
|
|
i need a c script to list the devices in the sytem. any one know this. help me.
Arise Awake Stop Not Till ur Goal is Reached.
|
|
|
|
|
Hi All,
Can anyone please tell me what is the difference between a DLL file,.Lib file .tlb file.
I am little confused about them.
Thanking you,
Ashwath.
|
|
|
|
|
ashwath1979 wrote: .Lib file
Static library is a lib
ashwath1979 wrote: DLL file
A dynamic library is a DLL
ashwath1979 wrote: .tl
Type libraries can be standalone files with a .tlb extension, or they can be embedded in a file as a resource. They are typically contained in files with the extension .dll, .exe, .ocx, or .olb. A quick way to check for the presence of a type library in a file is to try opening the file in OLEVIEW.EXE
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
Thanks ,One more doubt i have,
I have a exe.And calling a COM dll "example.dll" .In that there are some methods.I am calling those methods from my exe.To compile the exe
1.)where should the dll be residing.
2.)Is the .lib file required as i am loading the file dynamically by calling createinstance COM API.
3.)Why am i getting .lib not found error.
thanking in advance,
Ashwath Hegde.
|
|
|
|
|
1) anywhere in Windows path (for the application can find it). generally, you put it in the same folder as the one containing the exe.
2).lib files are for static link only AFAIK, but i don't know much about them.
3)did you look in your project settings that the full pathed lib where correctly provided, so that the linker can find it and link it ?
|
|
|
|
|
Thanks ,One more doubt i have,
I have a exe.And calling a COM dll "example.dll" .In that there are some methods.I am calling those methods from my exe.To compile the exe
1.)where should the dll be residing.
2.)Is the .lib file required as i am loading the file dynamically by calling createinstance COM API.
3.)Why am i getting .lib not found error when i am loading the Dll dynamically.
thanking in advance,
Ashwath Hegde.
|
|
|
|