|
This gives a new error:
d:\my documents\myprojects\webbrowse\webbrowseview.h(21) : error C2143: syntax error : missing ';' before '*'
d:\my documents\myprojects\webbrowse\webbrowseview.h(21) : error C2501: 'CWebBrowseDoc' : missing storage-class or type specifiers
d:\my documents\myprojects\webbrowse\webbrowseview.h(21) : error C2501: 'GetDocument' : missing storage-class or type specifiers
WebBrowse.cpp
|
|
|
|
|
Hi,
If you are getting missing storage class specifier or undeclared identifier errors
1. Check whether you have entered the variable name correctly(spelling,case etc..)
2. Check whether you have added the required header files.
3. Check whether such function, class exists in MFC or in the library u r using.
Include the doc header file and try .
Thanks and Regards,
Cool Ju
Dream ur Destiny
|
|
|
|
|
|
were you able to solve the problem ?
-Prakash
|
|
|
|
|
no
I suppose that should something about my compiler
-- modified at 5:34 Thursday 5th January, 2006
|
|
|
|
|
no its not the compiler, you have not included the files properly,
Can you dump here the list of files that you have included in the frm file?
-Prakash
|
|
|
|
|
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]--
|
|
|
|