Click here to Skip to main content
15,887,849 members
Home / Discussions / C#
   

C#

 
GeneralRe: how to change the title bar of the form in c#.net Pin
EliottA8-Apr-09 3:13
EliottA8-Apr-09 3:13 
GeneralRe: how to change the title bar of the form in c#.net Pin
Rajdeep.NET is BACK7-Apr-09 20:34
Rajdeep.NET is BACK7-Apr-09 20:34 
AnswerRe: how to change the title bar of the form in c#.net Pin
#realJSOP7-Apr-09 23:48
mve#realJSOP7-Apr-09 23:48 
QuestionRecord desktop Pin
yesu prakash7-Apr-09 18:59
yesu prakash7-Apr-09 18:59 
AnswerRe: Record desktop Pin
Christian Graus7-Apr-09 19:12
protectorChristian Graus7-Apr-09 19:12 
AnswerRe: Record desktop Pin
King Julien7-Apr-09 20:24
King Julien7-Apr-09 20:24 
QuestionCrystal Report Displaying multiple data (Each row twice) . Pin
aashish.saalvi7-Apr-09 18:03
aashish.saalvi7-Apr-09 18:03 
Questioninternet explorer control Pin
jorrod7-Apr-09 15:57
jorrod7-Apr-09 15:57 
I have made a little program that when i open the IE and puts url google.com i should go to microsoft.com for exemple in the same window, but it opens a new ie windows and goes to the site can someone help.

the code

detect new ie open
private void Form1_Load(object sender, EventArgs e)
{
shellWindows.WindowRegistered += new SHDocVw.DShellWindowsEvents_WindowRegisteredEventHandler(detect_ie);

}

private void detect_ie(int z)
{
foreach (SHDocVw.InternetExplorer ie in shellWindows)
{

ie.BeforeNavigate2 += new SHDocVw.DWebBrowserEvents2_BeforeNavigate2EventHandler(ie_BeforeNavigate2);



}

}



Detects the url open and goes to new url


void ie_BeforeNavigate2(object pDisp, ref object URL, ref object Flags, ref object TargetFrameName, ref object PostData, ref object Headers, ref bool Cancel)
{

object Flags2 = Flags;
object TargetFrameName2 = TargetFrameName;
ur=URL.ToString();

int tamanho =0;
int cont =0;
while (cont < 3)
{
tamanho = tamanho + 1;
if (ur[tamanho] == '/')
{
cont = cont + 1;
}
}
ur = ur.Substring(0, tamanho);

if (ur == "www.microsoft.com")
{
URL="www.google.com";
SHDocVw.InternetExplorer ie = new SHDocVw.InternetExplorer();
URL = "www.google.com".ToString();
ie.Navigate2(ref URL, ref Flags, ref TargetFrameName, ref PostData, ref Headers);
}
AnswerRe: internet explorer control Pin
Christian Graus7-Apr-09 17:42
protectorChristian Graus7-Apr-09 17:42 
GeneralRe: internet explorer control Pin
jorrod8-Apr-09 1:27
jorrod8-Apr-09 1:27 
QuestionMaking video call Pin
Darken19897-Apr-09 15:34
Darken19897-Apr-09 15:34 
AnswerRe: Making video call Pin
Christian Graus7-Apr-09 17:38
protectorChristian Graus7-Apr-09 17:38 
QuestionCrystal Reports Pin
CodingYoshi7-Apr-09 11:06
CodingYoshi7-Apr-09 11:06 
AnswerRe: Crystal Reports Pin
Mycroft Holmes7-Apr-09 12:28
professionalMycroft Holmes7-Apr-09 12:28 
QuestionIn search of a good PDF viewer control for .NET WinForms Pin
gongchengshi7-Apr-09 10:04
gongchengshi7-Apr-09 10:04 
AnswerRe: In search of a good PDF viewer control for .NET WinForms Pin
Christian Graus7-Apr-09 10:45
protectorChristian Graus7-Apr-09 10:45 
QuestionButton does not generate clicked events after validating textbox in a usercontrol Pin
hmvo247-Apr-09 9:44
hmvo247-Apr-09 9:44 
QuestionRTCP Packet in .net (c# or vb.net) Pin
Saurabh90907-Apr-09 9:11
Saurabh90907-Apr-09 9:11 
QuestionLaunching and Saving an Excel file from Winform Pin
DevWithDoutbs7-Apr-09 8:43
DevWithDoutbs7-Apr-09 8:43 
AnswerRe: Launching and Saving an Excel file from Winform Pin
Rolf Jaeger15-Jun-09 17:25
Rolf Jaeger15-Jun-09 17:25 
QuestionUsing StreamWriter...... Help Guys [modified] Pin
Rajdeep.NET is BACK7-Apr-09 8:32
Rajdeep.NET is BACK7-Apr-09 8:32 
AnswerRe: Using StreamWriter...... Help Guys Pin
behzadcp7-Apr-09 8:40
professionalbehzadcp7-Apr-09 8:40 
GeneralRe: Using StreamWriter...... Help Guys Pin
Rajdeep.NET is BACK7-Apr-09 8:44
Rajdeep.NET is BACK7-Apr-09 8:44 
AnswerRe: Using StreamWriter...... Help Guys Pin
Ashfield7-Apr-09 20:55
Ashfield7-Apr-09 20:55 
GeneralRe: Using StreamWriter...... Help Guys Pin
al3xutzu007-Apr-09 22:45
al3xutzu007-Apr-09 22:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.