Solved

Opening URL to a new window?

Posted on 2000-05-09
11
218 Views
Last Modified: 2013-11-20
Hi,
I have developed an app that is using CHtmlView class to display HTML docs in my dialogs. But the problem is that when I right click on a link and say "Open link in new window" it opens another instance of IE, which I don't want. Instead I want that my own new view should be generated. How can I do this.
Thanks in advance.
0
Comment
Question by:Moin
  • 6
  • 3
  • 2
11 Comments
 
LVL 30

Expert Comment

by:Zoppo
ID: 2791817
Hi Moin,

I think (but do not know, cause I have no experience with this) you'll have to override you view's CHtmlView::OnNewWindow2() where you can create a new view and assign it to the passed LPDISPATCH pointer.

hope that helps,

ZOPPO
0
 
LVL 30

Expert Comment

by:Zoppo
ID: 2791818
See MSDN article ID: Q184876 for samples of this...
0
 

Author Comment

by:Moin
ID: 2795594
This question has a deletion request Pending
0
 
LVL 30

Expert Comment

by:Zoppo
ID: 2795765
This question no longer is pending deletion
0
 
LVL 30

Expert Comment

by:Zoppo
ID: 2795766
Why do you want to delete this task?
0
6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

 

Expert Comment

by:maharia
ID: 2798861
Hi Moin,
  If you want to open your link to new IE window  then you just pass string to this function... and check for complete path od iexplore.exe....

ShellExecute(NULL,"open","C:\\Program Files\\Internet Explorer\\iexplore.exe",yourUrlString,NULL,SW_SHOW);
 
try out this and let me know.....
0
 

Author Comment

by:Moin
ID: 2798883
Please read my question carefully. Infact what you have proposed is currently happening to me and I don't want to happen this to me. :)
Thanks anyway for your time.
0
 

Expert Comment

by:maharia
ID: 2798922
Dear Moin,
 I had same problem as you but i tried this.... and got success...
why don'y you try and then reject answere...

.....

ShellExecute(NULL,"open","C:\\Program Files\\Internet Explorer\\iexplore.exe",yourUrlString,NULL,SW_SHOW);
0
 
LVL 30

Expert Comment

by:Zoppo
ID: 2799170
Ehh, Moin,

what do you think about the comments I gave you? Did they help you? I think MSDN article Q184876 describes detailed exactly what you need...

ZOPPO
0
 

Author Comment

by:Moin
ID: 2803789
Mr. Zoppo, pls. post your comment as answer. Thanks
0
 
LVL 30

Accepted Solution

by:
Zoppo earned 100 total points
ID: 2803831
You're welcome...

have a nice day,

ZOPPO
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now