|
Hello
I would like to save html source with pictures as the function "Save as " of Internet Explorer
I have no problem to save Html code with function like OpenRequest or InternetWriteFile but I don't arrive to save pictures.
Thank you for help
Nexus
|
|
|
|
|
First of all, Internet Explorer does not expose any (supported) API to save the current web page with all images, or even as a single-file archive.
You have workarounds, however :
- If InternetExplorer (stand-alone or web control) is visible on screen, then you can request the SaveAs dialog box, and automatically fill the appropriate values in it. Read this[^] article for more details.
- As soon as the web page is displayed on screen, it's available in the cache. It happens that there is an API dedicated to reading the cache. Be sure to understand that all pictures from a given web page share the same web page URL (obvious in the namespace extension when you browse the temporary internet files folder). For more info, lookup this API method in MSDN : FindFirstUrlCacheEntry.
|
|
|
|
|
Hi, I'm a student using Visual C++ to program regular C programs for school and I can't seem to figure out how to do something like
"a.out < 100.txt"
in Visual C++ (in other words, a.out would normally take input from stdin but in this case would take it from 100.txt). or even if someone could tell me how set command line input, that would be really helpful.
For instance, if my program were designed to take input specifically from a file, whose name should be the second argument in the command line, how do I specify the file name in Visual C++?
I am using a win32 Console Application type project.
Any help that can be given would be VASTLY appreciated.
Thank you.
|
|
|
|
|
DOS uses the same syntax for redirecting input and output
silverthread wrote:
designed to take input specifically from a file, whose name should be the second argument in the command line, how do I specify the file name in Visual C++?
Again, same way as Unix, the argc and argv parameters to main() .
--Mike--
When 900 years old you reach, look as good you will not. Hmm.
1ClickPicGrabber - Grab & organize pictures from your favorite web pages, with 1 click!
My really out-of-date homepage
Sonork-100.19012 Acid_Helm
|
|
|
|
|
Hello there.
Well when I try to load my VC6 project in VC++.NET everything is ok, but the buttons are still these bad-looking Win98 Buttons.My application is Dialog-Based....
When I try to do the most simple dialog app in VC++.NET I got the new-style buttons.
My question is how to port my dialog-bassed app written in VC6 to VC++.NET so it haves th WinXP buttons look ?
Thanx in advance...
|
|
|
|
|
Try this[^].
Software Zen: delete this;
|
|
|
|
|
10x Gary.
Now my old app looks great
Is that the proper way of doing that?I mean isn't it some kind of an undocumented hack?
|
|
|
|
|
That's precisely the way you're supposed to do it. It's not an 'undocumented hack' if Microsoft tells you how to do it .
I know it's weird that's all it takes. Now, if you're using ownerdraw controls, or third party ActiveX stuff, it gets tougher. With ownerdraw controls, you have to use the 'Theme API' in order to get the same visual effects that Windows is using. With third party ActiveX controls, you have to hope that the manufacturer of the controls make the same kind of changes.
Software Zen: delete this;
|
|
|
|
|
when I use auto complete function in a MFC project, it even dose not list 'CRect' and 'RECT' member, pls tell me how to change it back?
Thanks.
bill
|
|
|
|
|
If the project is named project.dsp (or project.vcproj if you are using VS.NET), delete the file named project.ncb. The IDE will recreate it as necessary. This file contains the 'parse-as-we-go' information used by IntelliSense for auto-completion.
Software Zen: delete this;
|
|
|
|
|
|
hi,
i want to refresh my IE instance in a certain interval of time say 5 mins even if user leaves the screen as it is( idle). Cna anyone help me out, i don't have a clue where to start with.
waiting for a positive reply soon...
thanks in advance...
Himanshu
|
|
|
|
|
Since you're asking for a timer, thats very easy to accomplish:
Just call SetTimer(yourWnd, 0, 1000*60*5, NULL and then simply catch the WM_TIMER -message in your app.
regards
modified 12-Sep-18 21:01pm.
|
|
|
|
|
If you mean you want the web page to refresh itself, add this in the <head> section of the page:
<meta http-equiv="refresh" content="300"> That makes the page reload every 5 min (300 sec).
--Mike--
When 900 years old you reach, look as good you will not. Hmm.
1ClickPicGrabber - Grab & organize pictures from your favorite web pages, with 1 click!
My really out-of-date homepage
Sonork-100.19012 Acid_Helm
|
|
|
|
|
(Dear mike,
I am making a vc++ application that interacts with IE instance. And it has a control on which i want to display information which might or might not change in every 5 mins. So i need a timer to set the time and refresh the contents on my application. as you suggested is a HTML way to do. But i guess I don't need any HTML in this. Anyway thanks a lot and i Hope my problem is clear to you. If you can help you are most welcome.
thanks a lot..
Himanshu
|
|
|
|
|
I have an dialog box that have a button in it.I want to change the caption OK button of it before DoModal() but it caused unhandled error.(Assertion failed).
CMyDlg a;
a_btn.SetWindowText("MyText");
a.DoModal();
Mazy
"And the carpet needs a haircut, and the spotlight looks like a prison break
And the telephone's out of cigarettes, and the balcony is on the make
And the piano has been drinking, the piano has been drinking...not me...not me-Tom Waits
|
|
|
|
|
What environment are you in? MS VC6?
What don't you just change it in the resource editor?
or are you trying to change it on the fly?
Later,
JoeSox
www.joeswammi.com
"Stand back! I know what I'm doing."
|
|
|
|
|
JoeSox wrote:
What environment are you in? MS VC6?
VC7.
JoeSox wrote:
What don't you just change it in the resource editor?
or are you trying to change it on the fly?
I want to do it in runtime.
Mazy
"And the carpet needs a haircut, and the spotlight looks like a prison break
And the telephone's out of cigarettes, and the balcony is on the make
And the piano has been drinking, the piano has been drinking...not me...not me-Tom Waits
|
|
|
|
|
Nevermind my other post, I don't think SetWindowText is what you need to call.
try
The SetDlgItemText function sets the title or text of a control in a dialog box.
BOOL SetDlgItemText(
HWND hDlg, // handle of dialog box
int nIDDlgItem, // identifier of control
LPCTSTR lpString // text to set
);
see the mfc help, for more info
Later,
JoeSox
www.joeswammi.com
"Stand back! I know what I'm doing."
|
|
|
|
|
aDlg.SetDlgItemText(IDOK,"sometext");
No change.Still the same problem.
Mazy
"And the carpet needs a haircut, and the spotlight looks like a prison break
And the telephone's out of cigarettes, and the balcony is on the make
And the piano has been drinking, the piano has been drinking...not me...not me-Tom Waits
|
|
|
|
|
The dialog and its controls aren't created until DoModal() is called. The correct place to set the button text is OnInitDialog() .
--Mike--
When 900 years old you reach, look as good you will not. Hmm.
1ClickPicGrabber - Grab & organize pictures from your favorite web pages, with 1 click!
My really out-of-date homepage
Sonork-100.19012 Acid_Helm
|
|
|
|
|
Oh,thanks.
Mazy
"And the carpet needs a haircut, and the spotlight looks like a prison break
And the telephone's out of cigarettes, and the balcony is on the make
And the piano has been drinking, the piano has been drinking...not me...not me-Tom Waits
|
|
|
|
|
hi,
try doing this..
oninitdialog write the bit of code like
a_btn.SetWindowText("MyText");
before your dialog loads it will set the caption to what you want. not before domodal() because your dialog doesn't exist physically where you write domodal(). I guess that's why you are facing the problem. try doing this i guess this should work..
cheers..
Himanshu
|
|
|
|
|
hi all,
i am stuck..can anyone help... I want to run an exe on click of a button..can i do so..If yes can anyone guide me...please..
Thanx zillions in advance..
Himanshu
|
|
|
|
|
you can use ShellExecute function:
ShellExecute(hwnd,"open","C:\file_path",NULL,NULL,0)
the last three arguments specify working directory , parameters ...etc.
|
|
|
|