|
I have a little sample ready, can I send it to you? it's really simple:
2 dialogs and 3 buttons...
What do you think about it?
Thank you in advance.
|
|
|
|
|
Hello,
I'd like to tell you that I'm very sorry to annoy you with my problems... I don't like to do it, but I need to solve those problems as fast as I can... the program is now installed in an industrial PC that controls a machine and after some hours the PC crashes...
I hope that after seeing the little program you'll be able to tell me how stupid I've been to pass a surely easy thing...
As I said before (in other post) I'm dealing with those pointers and HTML for first time...
Thank you in advance, and please, if you don't want me to send you the sample, feel free to tell it to me, you've been trying to help me for a long time and I don't want to annoy you more...
|
|
|
|
|
Hello, I've written down (and posted) an article on how to place HTML inside a dialog (from Paul DiLascia) and how to change it dynamically, it is about what I've been asking you those days...
Would you be so kind to take a look at it? you could download the demo project and see what happens directly...
this is the direction of the article: http://www.codeproject.com/useritems/HTMLCtrlSample.asp[^]
Thank you in advance.
|
|
|
|
|
Joan,
Can you explain what you are trying to accomplish in step 3. Is this just to give you a blank html page to work with or ...??
Neville Franks, Author of ED for Windows. www.getsoft.com
Make money with our new Affilate program
|
|
|
|
|
In step 1 or 2 I make the browser to load a blank page in order to be able to work with it (create a new page).
In step 3 I modify the contents of the newly created HTML page using a CString that contains the code that I want to appear inside the HTML page.
Then, as I don't know how to tell the HTMLView to create a new HTML page to work with it, I make the HMLView to navigate to a blank page (steps 1 or 2 ) and then I modify this page (step 3 ).
hope this clarify what I'm trying to do...
Thank you for your interest.
|
|
|
|
|
Hi Joan,
Another simpler way to replace your page is as follows:
1) In your blank page add an id attribue to the body tag. eg:
<body id="mybody">
2) The use this code:
MSHTML::IHTMLDocument2Ptr pDoc( GetHtmlDocument() );
MSHTML::IHTMLElementPtr e;
e = pDoc->Getall()->item( _T("mybody") );
if ( e != NULL )
{
e->PutinnerHTML( (LPCSTR)sYourString.GetBuffer() );
sYourString.ReleaseBuffer();
}
This replaces all the html between the open and close body tags. It should do what you want.
Neville Franks, Author of ED for Windows. www.getsoft.com
Make money with our new Affilate program
|
|
|
|
|
the problem (I think) is that I'm not using CHTMLView in an ordinary view, I'm doing it in a dialog...
Do you mean that I should do this in the creation?
this->Navigate2(_T("about:<html><body id=\"mybody\"></body></html>"), navNoHistory); I'm prepairing an article about this but I would like to catch the handle that is being missed...
Could I send you a little demo project prepared to reproduce the problem only pressing two keys?
Then you would be able to see exactly what is happening...
Thank you in advance...
|
|
|
|
|
Hello, I've written down (and posted) an article on how to place HTML inside a dialog (from Paul DiLascia) and how to change it dynamically, it is about what I've been asking you those days...
Would you be so kind to take a look at it? you could download the demo project and see what happens directly...
this is the direction of the article: http://www.codeproject.com/useritems/HTMLCtrlSample.asp[^]
Thank you in advance.
|
|
|
|
|
hi,
I have this problem that wenn i begin printing a drawing with Visual C++ it doesn't fill a rectangle. i just use the function:
<br />
void CRSARuitLocaties::SelectPrintRuit(CDC *dc, CRect r, FLOAT Factor, int Ruitnr)<br />
{<br />
m_strFilter.Format("Nr = %d", Ruitnr);<br />
Open();<br />
<br />
int x,y;<br />
<br />
CBrush* brush;<br />
CBrush* oldBrush;<br />
<br />
brush = new CBrush(RGB(255,0,0));<br />
<br />
while(!IsEOF())<br />
{<br />
oldBrush = dc->SelectObject(brush);<br />
<br />
x = r.left + (m_xmiddel / Factor);<br />
y = r.top - (m_ymiddel / Factor);<br />
<br />
dc->FloodFill(x, y, RGB(0,0,0));<br />
dc->SelectObject(oldBrush);<br />
MoveNext(); <br />
}<br />
<br />
delete brush;<br />
<br />
Close();<br />
}<br />
the locations are right, i've checked...
|
|
|
|
|
|
|
my problem is:
I have a file, where I write some data(for example name, description, date). and I have to delete one record. how do I have to do this?
|
|
|
|
|
Using C or C++ functions?
How are u writing to the file
Anyway consider using fseek or CFile:Seek and be sure u dont open in append mode
|
|
|
|
|
I am writing like this:
"ses" is my serializable class
I want to save "name" and "date"
ses.Add(name);
ses.Add(date);
and after I am writing into the file.
mode "write".
|
|
|
|
|
I have two modeless dialogs (two different classes). Each has a textbox. I want to see when the user pressed Enter - SO I overrride OnCommand() in both of the CDialogs. Now if I press enter in the Dilaog#1 textbox, the OnCommnad of that class will run. But wil the OnCommnad of the other class run too? Or does the message (WM_COMMAND) generated on pressing Enter pertain only to the window in which the enter key was pressed?
Appreciate your help,
ns
|
|
|
|
|
You can you PreTranslateMessage defined in each dialog class.
BOOL CYourClass::PreTranslateMessage( MSG* pMsg )
{
if ( (pMsg->message == WM_KEYDOWN) && (pMsg->wParam == VK_RETURN) )
{
return TRUE;
}
return CYourBaseClass::PreTranslateMessage(pMsg);
}
Max.
Maximilien Lincourt
For success one must aquire one's self
|
|
|
|
|
Thank you! I will try it.
Appreciate your help,
ns
|
|
|
|
|
Exactly what I needed.
Appreciate your help,
ns
|
|
|
|
|
Is it possible to use get to read a file in as a string without the whitespace characters.
I have done this effectively by using >> and a loop but I was wondering if I could do it with get.
btw I have called File.setf(ios::skipws) without success.
|
|
|
|
|
>> will skip whitespace, otherwise you should use getline and then remove the whitespace afterwards. Or you could create your own inserter which does not read whitespace. iostreams has no inserter for CString, so if you're using MFC, just write it for CString and all will be well.
Christian
NO MATTER HOW MUCH BIG IS THE WORD SIZE ,THE DATA MUCT BE TRANSPORTED INTO THE CPU. - Vinod Sharma
Anonymous wrote:
OK. I read a c++ book. Or...a bit of it anyway. I'm sick of that evil looking console window.
I think you are a good candidate for Visual Basic. - Nemanja Trifunovic
|
|
|
|
|
Thanks for the info, I guess I'll stick to >> and my while loop...
|
|
|
|
|
I would appreciate it if someone could give me the correct syntax (or parameters) to use on the add method of the worksheets object. I have an application where I am doing Excel automation. I have been able to add data to the three existing worksheets but when I try to add a fourth sheet to the end I get a method failure message. If I use 'vtMissing' for all four parameters of the add method, the new worksheet gets added to the beginning. I then tried to use the move method, but I get a method failure error if I try to put the sheet number that I want to move after.
VC++ 5
Oracle ODBC
ADO
Excel 2000
|
|
|
|
|
Hello
Per a few suggestions I have looked for and found one of the splitter demos on this site. As I have mentioned before I am very new to Visual C++. The splitter demo I found is at the following location: http://www.codeproject.com/splitter/SimpleDlgSplitter.asp
I am looking over it and would like to know how I can change it to have two windows side by side and how to chnage the left window so that it is dialog based. I have found the portion of the code to allow me to changethe size of the window. Any help that anyone can provide will be greatly appreciated as I embark on learning a new programming language.
Thanks
Spamdogg
|
|
|
|
|
Our local computer club would like to find a way to automate the dial up networking information for our club's Internet connection as an installation program that would be easy for new computer users to run in order to set up their connections. Does anyone have any suggestions on how to do this or know where to find documentation on this. Am assuming you'd have to insert/modify information in the registry, but I'm not sure what information would be needed. Has anyone run across registry documentation on the subject or know of an easier way of doing this? Thanks.
http://www.distasis.com/cpp/
|
|
|
|
|
Hi all,
How would one go about determining IE's current cipher strength (as displayed by the About box) programmatically, from a VC++ app?
What should be assumed for older versions that don't display it anywhere at all?
While I'm at it, where is the current IE service pack number stored?
|
|
|
|