-
August 30th, 2013, 05:58 PM
#1
Using CDHtmlDialog
Hello,
I am trying to use CDHtmlDialog in a MFC dialog based project.
What i want to achieve is pretty sample. Have one image, one button and one text box in the HTML page.
And then dynamically change this based on a timer. i.e., there're multiple images in the folder and it will change every seconds. Once the button is clicked, the timer stops and no more image changes. Same time when image changes the text in the text box also should change.
I know this is pretty simple, but for some reason i am not able to make the image even display in the dialog.
I am using Visual Studio 2012 in Windows 7 machine.
Can somebody share some sample code that does this?
I appreciate your help.
Thanks in advance.
-
September 1st, 2013, 03:18 AM
#2
Re: Using CDHtmlDialog
Victor Nijegorodov
-
September 2nd, 2013, 11:26 AM
#3
Re: Using CDHtmlDialog
I have few specific questions :-)
1. When i try to build the sample projects from web in the Visual Studio 2012, it gives the following error --> atlmfc\include\atlwinverapi.h(29): fatal error C1189: #error : This file requires _WIN32_WINNT to be #defined at least to 0x0403. Value 0x0501 or higher is recommended.
How to fix this?
2. In the project i created, i am trying to load an image into the DHTML page and that doesn't work. How to load the image into the DHTML page? Also how to change the image in a DHTML page from the MFC code?
2. How can i change the text in a DHTML page from the MFC code?
Thanks in advance.
-
September 2nd, 2013, 02:39 PM
#4
Re: Using CDHtmlDialog
Originally Posted by Don Guy
I have few specific questions :-)
1. When i try to build the sample projects from web in the Visual Studio 2012, it gives the following error --> atlmfc\include\atlwinverapi.h(29): fatal error C1189: #error : This file requires _WIN32_WINNT to be #defined at least to 0x0403. Value 0x0501 or higher is recommended.
How to fix this?
2. In the project i created, i am trying to load an image into the DHTML page and that doesn't work. How to load the image into the DHTML page? Also how to change the image in a DHTML page from the MFC code?
2. How can i change the text in a DHTML page from the MFC code?
Thanks in advance.
Add this line in the stdafx.h file:
Code:
#define _WIN32_WINNT 0x0501
Victor Nijegorodov
-
September 3rd, 2013, 01:49 AM
#5
Re: Using CDHtmlDialog
Originally Posted by Don Guy
2. In the project i created, i am trying to load an image into the DHTML page and that doesn't work.
How do you know it doesn't work when you're not able to build your project?
How to load the image into the DHTML page?
Do you have any knowledge in HTML programming? If you don't, you'd better start with getting into that first rather than doing CDHtmlDialog.
Also how to change the image in a DHTML page from the MFC code?
You get the element and set it up appropriately, I believe.
2. How can i change the text in a DHTML page from the MFC code?
Again, you get the element and set it up appropriately.
Best regards,
Igor
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|