|
Hi! I am interested in computer animation and I don't know if I could use visual c++/MFC to make it. All I want is to have a sort of an application that shows a flash screen with animation on it and sounds maybe and I don't know if I could do it in MFC. So if you have tried using MFC/Visual C++ making such things please help me?
|
|
|
|
|
You can create a window that shows Flash in an MFC app. I think from memory it's an ActiveX control you add. If you get stuck, LMK, I have a project kicking around where I did it.
Christian
#include "std_disclaimer.h"
People who love sausage and respect the law should never watch either one being made.
The things that come to those who wait are usually the things left by those who got there first.
|
|
|
|
|
If you are talking about a splash screen. Then just go to add to project->visual C++ folder and click on splash screen. It will automatically generate a CSplash class that will do this flash screen that you are talking about. If you are talking about something else then Oh well.
Big Man On Campus
|
|
|
|
|
I am writing an Outlook 97 Extension in VC++. I need to access the tasks folder/object. I have declared the IOutlookExtCallback interface but now am stuck as to the next move.
The only function that IOutlookExtCallback provides is a single parameter GetObject function.
I also have sample code that gives returns an IDispatch object from an IOutlookExtCallback object.
Can I get a pointer to a folder object using any of that or am i pulling at straws?
There is sparse sample code on this subject.
Cheers
Robbie G
|
|
|
|
|
Not sure if these will be of any use to you
http://www.darkweb.com/~beng/exchange/book/dame.htm
http://www.darkweb.com/~beng/exchange/mdevfaq.htm
http://www.slipstick.com/outlook/index.htm
Michael
|
|
|
|
|
I have created an ATL Service exe project, which spawns some worker threads to act as a socket server.
The big issue right now is that when the exe is running, no other programs will start up until my exe is shut down; then all the other programs suddenly launch.
Any help would be greatly appreciated.
|
|
|
|
|
Hi!
Does anybody know how to make a control that, when displayed in the Properties Window of VB6, for some properties be able to display a list of constants? The user should be able to select the desired value.
I am trying to implement this by implementing the IPerPropertyBrowsing interface. It works when I want that all properties to have list of constants.
The problem is that I want that one property to have such a list and another property to be simple, without list.
The default implementation found in ATL seems to not work with VC++ 6.0 (the properties without 'list' are not editable)
The IPerPropertyBrowsing interface has 4 methods.
I found that for the method GetDisplayString(...), if I return E_NOTIMPL for a simple property, it is displayed correct in VB but not in VC++.
It would be great if someone could show a tip how to make the properties to be displayed correctly in the Properties Window.
Thank you very much!
|
|
|
|
|
OK, here's the situation. I'm working on a dialog-based app and I would
like to use a tab control and a "sheet" for each tab. Each "sheet" is a
dialog that is the child of the tab control. I have a few problems I am
trying to work out, and I think all of them are in the message-handling
code.
Problems:
1. Each sheet is not placed directly under the tabs, instead it is placed
right over them. Is there a function I should call to get the rect of the
display area right below the tabs?
2. When the dialog is first opened, no sheet is shown. Do I put the
ShowWindow call in WM_INITDIALOG, or somewhere else?
3. When I try to click on any control in any of the sheets, my app freezes.
Are there any parameters I need to set to overcome this?
4. Ctrl-Tab doesn't work for some reason. Do I need to implement this
myself, or is it supposed to be automatically supported?
Below is the code for the message handler of the tab control. Please note
that hPropPage is an array of HWND's to each sheet in the tab control, and
hTabCtrl is an HWND to the tab control window. Sorry if this code looks
messy, as I'm new to the Win32 API. Also, please note that I cannot use MFC
or any other API and I'm programming in C, not C++.
Thanks
-Lito
static BOOL CALLBACK ConfigProc(HWND hwndDlg, UINT uMsg, WPARAM wParam,
LPARAM lParam)
{
NMHDR nmhdr;
int i;
switch (uMsg)
{
case WM_COMMAND:
switch (LOWORD(wParam))
{
// For now, they do the same...
// In the future, any changes will be saved
// as soon as user does the change, and
// the Cancel button needs to perform a rollback
case IDOK:
case IDCANCEL:
EndDialog(hwndDlg, 0);
break;
}
return FALSE;
case WM_INITDIALOG:
// Show the first page
byCurrentPage = 0;
ShowWindow(hPropPage[byCurrentPage], SW_SHOW);
return FALSE;
case WM_NOTIFY:
switch (((LPNMHDR)lParam)->code)
{
case TCN_SELCHANGING:
nmhdr.hwndFrom = GetDlgItem(hwndDlg, IDC_TAB);
nmhdr.idFrom = IDC_TAB;
nmhdr.code = PSN_KILLACTIVE;
byCurrentPage = TabCtrl_GetCurSel(hTabCtrl);
if(SendMessage(hPropPage[byCurrentPage], WM_NOTIFY, (WPARAM)IDC_TAB,
(LPARAM) &nmhdr))
{
// Prevent the selection from changing
SetWindowLong(hwndDlg, DWL_MSGRESULT, TRUE);
return TRUE;
}
// Hide the current child dialog box
ShowWindow(hPropPage[byCurrentPage], SW_HIDE);
UpdateWindow(hwndDlg);
break;
case TCN_SELCHANGE:
// Grab the index of the next page to display
byCurrentPage = TabCtrl_GetCurSel(hTabCtrl);
// Show the current page
ShowWindow(hPropPage[byCurrentPage], SW_SHOW);
// Let the page know it is now active
nmhdr.hwndFrom = hTabCtrl;
nmhdr.idFrom = IDC_TAB;
nmhdr.code = PSN_SETACTIVE;
SendMessage(hPropPage[byCurrentPage], WM_NOTIFY, (WPARAM)IDC_TAB,
(LPARAM) &nmhdr);
break;
}
return FALSE;
}
return FALSE;
}
|
|
|
|
|
Why aren't you using PropertySheet API function? Basically, you're trying to duplicate something that's already implemented in Windows.
If for some reason you want to do everything 'manually', use TCM_ADJUSTRECT to adjust child dialog position.
Tomasz Sowinski -- http://www.shooltz.com.pl
|
|
|
|
|
I get stuck with a simple program in C++ and I can't find what is the bug. Does anybody know a site, which help finding bugs?
Thanks, Noam
|
|
|
|
|
Yeah - this one. Just post your code and explain what the problem is.
You might also want to buy 'Debugging Windows' from M$ press. A *damn* fine book.
Christian
#include "std_disclaimer.h"
People who love sausage and respect the law should never watch either one being made.
The things that come to those who wait are usually the things left by those who got there first.
|
|
|
|
|
Hi there, I was wondering if anyone know how to make a static box contain text that blinks. I tried a rudimentary version that uses the sleep command, but I don't like that it has to be used. Is there any other way?
"There is no knowledge that is not power" - Disraeli
|
|
|
|
|
|
Hi,
1. I have a problem with resouce files: Visual C++ does not give unique ID numbers to all sysmbols and this sometimes causes many problems. How can I prevent this from happening again? Editing resource file manually really takes too much time.
2. I have a big project and I want to make a German version of my program. How can I do this?
Thank you for any helps in advance
Mustafa Demirhan
|
|
|
|
|
Hello, the codgurus around the world.;)
Actually, I don't understand your (1) problem very well.
One issue of Localization is that we shouldn't put the hard code of error string like MessageBox. We should use the string table in the resource file.
ID of the control should keep the same one in resource.h and control ID of the resource ID.
As long as we use the resource editor to add or delete the control, the resource editor
add the new ID to resource.h (not delete).
(2) If you need German version, you should simple replace English string to German string
in the resource file (RC file).
That is, German resource is included in EXE file.
Or, you can use the resource DLL file to linked EXE file at run time.
Check Localization in MSDN help.
Or, you can use Unicode version exe for Window NT and 2000.
Currently, Window 9x and ME don't support Unicode. But, Microsoft will support this in
the near future.
Have a nice day!
-Masaaki Onishi-
|
|
|
|
|
I have a (freeware) Add-In for VC 5.0/6.0 which can identify resource ID conflicts within a resource.h file and renumber symbols to get rid of them (unfortunately, there's not much that can be done about DevStudio mucking them up in the first place).
If you think this will help you feel free to visit http://www.resorg.co.uk.
P.S. I'm about to post a new version in the next week or so which is much smarter than the current one - if you're interested I'll let you know by email when it's available.
Andy Metcalfe - Sonardyne International Ltd (andy.metcalfe@lineone.net) http://www.resorg.co.uk
"I used to be a medieval re-enactor, but I'm (nearly) alright now..."
|
|
|
|
|
Hi all
I do have a simple quistion, can i recognize that my serialized file hade been changed externaly by any one ?
i do have a program that read every time from serialied file and i wan to be shoure that no one play with that file
another q can i compress my serialized file
thanks all
|
|
|
|
|
Add a digital signature to the file, and check it while reading. MS Crypto API has functions for this.
You can compress the data if you want.
|
|
|
|
|
If you are using serialization
you would be using CArchive for that purpose.
CArchive is associated with CFile Object.
Check the CFile object. Setting appropriate parameters for the file so that no one else modifies it is possible.
May be in one of the parameters you find a parameter for compressing the file. Or else use Low level Win32 api CreateFile there might be a way to compress the file if it is a NTFS file system. then attach this file handle to the CFile object.
|
|
|
|
|
I am wondering if anyone knows how to remove the labels on each point when doing charts/graphing with TeeChart Active X. Those labels really clutter up the graphs and it would be really nice to remove them. I think it's supposed to be easy, but I have not been able to figure it out.
Thanks.
|
|
|
|
|
Hi
I'm not familiar with databasing. and i have to use Microsoft Access.
I like to know if anyone knows any :
1-Usefull internet site for beginners.
2-Helpful book to teach beginners, Microsoft Access.
Thanks
Ehsan
Ehsan Behboudi
|
|
|
|
|
Easiest way to learn is start ADO. Get samples from msdn ADOChucnk is simple database
App. ADO is straight forward using Access Databse in ADO is very easy.
So best way is start with MSDN sample
Bad judgement gives Good experience;
Good judgement comes with Bad experience
|
|
|
|
|
I have this MFC app. where I have some dialogs, with some controls in. Nothing new there
But, I also have selected "Context Help" and have this little "?" in the corner of every dialog, but when I click the "?" and then click on a control, I can see in the help workshop that it's the dialogs help-id that's called, and not the controls help-id
Anybody knows how I get my app to call the controls help-id instead. I want popup-help for every control, not a general help for the dialog...
- Anders
Money talks, but all mine ever says is "Goodbye!"
|
|
|
|
|
You need to handle MFC-defined WM_HELPINFO message - that's the place to call WinHelp. The tricky part is that handler gets called for both dialog and control help. So you need also to handle WM_SYSCOMMAND, like this:
void CMyDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if (nID == SC_CONTEXTHELP)
{
m_bContextHelp = TRUE;
}
CDialog::OnSysCommand(nID, lParam);
if (nID == SC_CONTEXTHELP)
{
m_bContextHelp = FALSE;
}
}
m_bContextHelp is a BOOL data member which is tested in OnHelpInfo handler. If you have more than one dialog in your app put this stuff into common base class.
Tomasz Sowinski -- http://www.shooltz.com.pl
|
|
|
|
|
Thanks a lot, I'll give it a try
- Anders
Money talks, but all mine ever says is "Goodbye!"
|
|
|
|