|
Tanck you for y help
What is a frm file?
I just used the wizard. I placed a new member function in the CMainFrame:
public:
void OnNewAddress();
and in this function I used this line:
((CWebBrowseView*)GetActiveView())->Navigate(sAddress);
|
|
|
|
|
bruno957957 wrote: What is a frm file?
I meant the MainFrame.cpp file.
The problem is that youare not includeing the WebBrowserview.h in MainFrame.cpp file.
did you try that? put the include statement as the last include statement at the top.
-Prakash
|
|
|
|
|
Yes I tryed but this gives me other 3 error messages:
d:\my documents\myprojects\webbrowse\webbrowseview.h(22) : error C2143: syntax error : missing ';' before '*'
d:\my documents\myprojects\webbrowse\webbrowseview.h(22) : error C2501: 'CWebBrowseDoc' : missing storage-class or type specifiers
d:\my documents\myprojects\webbrowse\webbrowseview.h(22) : error C2501: 'GetDocument' : missing storage-class or type specifiers
|
|
|
|
|
What is the statement at line 22 in webbrowserview.h ?
I guess the first error has been solved, thisis a different problem.
-Prakash
|
|
|
|
|
// Attributes
public:
CWebBrowseDoc* GetDocument();
|
|
|
|
|
Seems like you have added this GetDocument() method in the mainframe class.
I guess you need to include the header file for CWebBrowserDoc too.
i would say that you might have not designed the app properly, i dont see any reason why a mainframe class is trying to get a refrerence to the document,usally the view class does that.
-Prakash
|
|
|
|
|
This thread looks like a rainbow. He he
Love Forgives--Love Gives--Jesus is Love <marquee direction="up" height="50" scrolldelay="1" step="1" scrollamount="1" style="background-color:'#44ccff'">
--Owner Drawn
--Nothing special
--Defeat is temporary but surrender is permanent
--Never say quits
--Jesus is Lord
|
|
|
|
|
|
I think you should handle the COMMAND events in the view class rather than in the Framewindow class.
-Prakash
|
|
|
|
|
Mr.Prakash wrote: i would say that you might have not designed the app properly, i dont see any reason why a mainframe class is trying to get a refrerence to the document,usally the view class does that.
Agreed. It's approaching a cyclic dependency.
"The words of God are not like the oak leaf which dies and falls to the earth, but like the pine tree which stays green forever." - Native American Proverb
|
|
|
|
|
void ExecuteCommand(ISpPhrase *pPhrase, HWND hWnd)
{
SPPHRASE *pElements;
if(SUCCEEDED(pPhrase->GetPhrase(&pElements)))
{
switch(pElements->Rule.ulId)
{
case VID_Trigger:
{
switch(pElements->pProperties->vValue.ulVal) //here
{
case VID_Read:
PostMessage(hWnd, WM_READ, NULL, NULL);
break;
}
}
break;
}
//free pElements
::CoTaskMemFree(pElements);
}
}
pPhrase is the result of an SPEI_RECOGNITION event.
ExecuteCommand(event.RecoResult(), hWnd);
For some reason, pPhrase isn't passing a value to pElements, but it passes the Rule ID. I tested the grammar with the grammar compiler provided in the Speech SDK, and it appears to be alright.
Grammar file-
<GRAMMAR LANGID="409">
<DEFINE>
<ID NAME="VID_Read" VAL="1" />
<ID NAME="VID_Trigger" VAL="253" />
<ID NAME="VID_Action" VAL="254" />
</DEFINE>
<RULE ID="VID_Trigger" TOPLEVEL="ACTIVE">
<P>
<L>
<P>I'd like to</P>
<P>I want to</P>
</L>
</P>
<RULEREF REFID="VID_Action" />
</RULE>
<RULE ID="VID_Action">
<L PROPID="VID_Action">
<P VAL="VID_Read">read</P>
</L>
</RULE>
</GRAMMAR>
maybe I'm adding my grammar as a resource the wrong way, I'm not sure (compiled, added the .cfg as a custom resource of type SRGRAMMAR)
anyone know what i'm missing here?
-- modified at 3:57 Thursday 5th January, 2006
|
|
|
|
|
In embedded systems there is a use of function pointer
But where can we use this in VC++.
Vikas Amin
Embin Technology
Bombay
vikas.amin@embin.com
|
|
|
|
|
CALLBACK's
Love Forgives--Love Gives--Jesus is Love <marquee direction="up" height="50" scrolldelay="1" step="1" scrollamount="1" style="background-color:'#44ccff'">
--Owner Drawn
--Nothing special
--Defeat is temporary but surrender is permanent
--Never say quits
--Jesus is Lord
|
|
|
|
|
vikas amin wrote: In embedded systems there is a use of function pointer
But where can we use this in VC++
C++ virtual functions employes virtual table, which contains pointers to the virtual functions.
Think broadly, functions pointers can be designed and used in C/C++ and not neccessarly in Embedded system.
Callback functions are an example, Windproc is another example, many Win32 enumeration APIs employ function pointers.
-Prakash
|
|
|
|
|
Can u tell me some example application
where i can implemt such things.
Vikas Amin
Embin Technology
Bombay
vikas.amin@embin.com
|
|
|
|
|
vikas amin wrote: Can u tell me some example application
where i can implemt such things.
google them
-Prakash
|
|
|
|
|
k thanks
Vikas Amin
Embin Technology
Bombay
vikas.amin@embin.com
|
|
|
|
|
Could someone please explain me the actual differences? My colleague says its possible for one to get the entire source code of an application if the debug mode output is shipped. MSDN says the compiler will generate Debugging symbols. What are they? Why it will ship the source code with the output? What happens internally when I change the active configuration (debug to release and vice versa) and build the project?
Many thanks,
Aljechin Alexander
|
|
|
|
|
release mode'd be the optimized one. while you are in development phase, you can use debugg mode. but once the program is perfectly ready , you shoud choose "release" mode. it will bring down the size completely.
>"My colleague says its possible for one to get the entire source code of an application if the debug mode output is shipped"
that's not true.
Check this one^
"But your mind is very complex, very tricky. It makes simple things complicated. -- that's its work. And for centuries it has been trained for only one thing: to make things so complicated that your life becomes impossible."- Osho
<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--
|
|
|
|
|
Thank you for reply. Quite an informative article.
Aljechin Alexander
|
|
|
|
|
Better to do development in Release mode only. In case any issues change to Debug and correct then back to Release. as the code base increases and an error occurred at the end of development when changed to Release mode ONLY....What you do?
Anilkumar
|
|
|
|
|
that's why then and there i take a copy of my project and test it with the Release Mode, mostly to check its size. and if i ever have problem in it. we have people here who can solve it at any point of time.so i never worry
"But your mind is very complex, very tricky. It makes simple things complicated. -- that's its work. And for centuries it has been trained for only one thing: to make things so complicated that your life becomes impossible."- Osho
<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--
|
|
|
|
|
T-1000 wrote: we have people here who can solve it at any point of time.so i never worry
Where ?
"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
|
|
|
|
|
here means, only CP!! and mostly people lik you
"But your mind is very complex, very tricky. It makes simple things complicated. -- that's its work. And for centuries it has been trained for only one thing: to make things so complicated that your life becomes impossible."- Osho
<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--
|
|
|
|
|