|
Hi Blake, sorry for late reply, been away!
If the settings are correct, it only supresses the error message for a specified app which is just what we want.
As it happens, it turned out to be a hardware issue (sorry Macromedia ) which was easily resolved but you are right, the program exceptions would have worked as well.
Thanks for the help!
|
|
|
|
|
Hi,
Is there any way to passing back to the parent dialog values of the child's Dialog variables ?
For example :
CCreateCategoryDlg dlg;
if (dlg.DoModal() == IDOK)
{
// In this point i want the access the strings of the dlg.ListBox
}
Regards,
George
sdancer
|
|
|
|
|
You can add public member variables or functions to the CCreateCategoryDlg class that return the results. Here's an example:
public CMyDialog : CDialog {
public:
virtual void OnOK();
int GetResult();
private:
int Result;
};
void CMyDialog::OnOK()
{
Result = list_box.GetCurSel();
}
int CMyDialog::GetResult()
{
return Result;
} Note that you can't reference the list box in the function GetResult() . At this point, the dialog window and its child controls have already been destroyed. This is the reason for the OnOK() handler, which is called when the user clicks the OK button, before the dialog is destroyed. Save the contents of the controls in the OnOK() handler, and then return those saved results in the "Get*" functions.
Software Zen: delete this;
|
|
|
|
|
Hi,
Iam working with a ListControl whose parent is a dialog. In one the cell of the listcontrol,I place a tree control which on doubleclicking should open up & overlap the dialog control.
I achieved the treecontroloverlapping by writing as follows:
treeControl.SetParent(GetDesktopWindow());
treeControl.ShowWindow(true);
treeControl.BringWindowToTop();
treeControl.SetFocus();
treeControl.MoveWindow(500,300,400,200);
Now,the problem I have in hand is that the overlapped treecontrol is not active.Can't do anything over there.
Tried "EnableWindow","SetActiveWindow" etc.but the overlapped treecontrol is not getting enabled.
Any help is appreciated...
Thanks...
|
|
|
|
|
Why not make the tree control's parent the dialog instead of the desktop window?
Just insert it in Z-order after the list control so that it will appear in front of the list control.
|
|
|
|
|
HiBlake,
I fixed the problem..
I had to Modify the style after setting the parent
m_gridControl.SetParent(GetDesktopWindow());
m_gridControl.ModifyStyle(WS_CHILD,WS_POPUP);
Thanks
|
|
|
|
|
Is there any way to obtain the name of the caller function in VC++?
eg:
Func1()
{
Func2()
}
I need to get the name of Func1() from Func2() using code.
Any help would be appreciated.
Thanks,
John
|
|
|
|
|
Unfortunately, there's no way to do that directly. The compiler does create a #define symbol called __FUNCTION__ , that is the name of the current function. You could modify your code as follows:
void Func2(char *caller);
void Func1()
{
Func2(__FUNCTION__);
}
void Func2(char *caller)
{
TRACE(_T("Func2 called by %s.\r\n"),caller);
} Everywhere you call Func2 use Func2(__FUNCTION__); .
Software Zen: delete this;
|
|
|
|
|
Gary R. Wheeler wrote: The compiler does create a #define symbol called __FUNCTION__
is there something you need to do to enable this? or is this not available in VC6 ?
Cleek | Image Toolkits | Thumbnail maker
|
|
|
|
|
This may be a VC7.1 feature, as that's the only compiler where I've used it. There's no option required to enable it. The value is the fully-resolved name of the function, e.g. base1::base2::...::function .
Software Zen: delete this;
|
|
|
|
|
__FUNCTION__ and the other related macros aren't in VC 6
--Mike--
Visual C++ MVP
LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ
"That probably would've sounded more commanding if I wasn't wearing my yummy sushi pajamas."
-- Buffy
|
|
|
|
|
|
Hello,
The callstack[^] is a usefull place to look for a function address and name. The only problem is that this only works in debug builds. Do you need this also in release builds? If so, you have to provide the *.pdb file with your application, which reveals vital information about your application.
Hope this helps.
Behind every great black man...
... is the police. - Conspiracy brother
Blog[^]
|
|
|
|
|
|
Hi
How to send a mail in background programatically without using outlook by using any SMTP server.
Regards
Anandan
|
|
|
|
|
Try http://www.blat.net/
The two most common elements in the universe are Hydrogen and stupidity. - Harlan Ellison
Awasu 2.2 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
http://www.naughter.com/smtp.html[^]
"You're obviously a superstar." - Christian Graus about me - 12 Feb '03
"Obviously ??? You're definitely a superstar!!!" - mYkel - 21 Jun '04
"There's not enough blatant self-congratulatory backslapping in the world today..." - HumblePie - 21 Jun '05
Within you lies the power for good - Use it!
|
|
|
|
|
> http://www.naughter.com/smtp.html
PJ...is your library supposed to work with VS 2005?
I have an app compiled with VC6 that's using it without any problem...however when I try to compile the project under VS2005 the linker gives the me following error:
smtp.obj - error LNK2001: unresolved external symbol "unsigned int (__stdcall* ATL::g_pfnGetThreadACP)(void)" (?g_pfnGetThreadACP@ATL@@3P6GIXZA)
Little help with that maybe? This is a plain windowless Win32 application. No MFC, no ATL...
|
|
|
|
|
Daniel Desormeaux wrote: > http://www.naughter.com/smtp.html
PJ...is your library
Same initials, different guy.
"You're obviously a superstar." - Christian Graus about me - 12 Feb '03
"Obviously ??? You're definitely a superstar!!!" - mYkel - 21 Jun '04
"There's not enough blatant self-congratulatory backslapping in the world today..." - HumblePie - 21 Jun '05
Within you lies the power for good - Use it!
|
|
|
|
|
> Same initials, different guy.
SOB...you know what, I've read your posts on CP for years, and for some reason I've made the assumption you were the guy. Once the initials stuck, I stopped paying attention to the last name.
Sorry 'bout that, man.
|
|
|
|
|
Can u tell me if i dont want to use any server in between &
want to send an email direcly with my application , how can
i do that . Assuming my compter has a internet connection .
I mean can i direclty subit an email to the yahoo server or
at pop3.yahoo.com .
Vikas Amin
Embin Technology
Bombay
vikas.amin@embin.com
|
|
|
|
|
at least ur system has to be mail server in the LAN
|
|
|
|
|
sunit5 wrote: at least ur system has to be mail server in the LAN
Nope, thats the another thing.. you can send mail to yahoo or any different mail sevrer by specifying the MX server.. see my reply to Vikas Amin
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
vikas amin wrote: I mean can i direclty subit an email to the yahoo server or
at pop3.yahoo.com .
Yes, check out this article
http://www.codeproject.com/tips/CSMTPConnection2.asp[^]
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|