11 Replies - 10963 Views - Last Post: 27 November 2010 - 07:19 PM Rate Topic: -----

#1 samforever1989  Icon User is offline

  • D.I.C Head

Reputation: -6
  • View blog
  • Posts: 53
  • Joined: 25-November 10

creating/opening new tab in our simple web browser in c#

Posted 26 November 2010 - 08:33 AM

Sir/Ma'm,
I just have created a simple web browser using c# with the help of dreamincode.net.
Could you please tell me how can we add feature of opening new tabs and viewing history.
Sir/Ma'm could you please send it on my emailID:
***MOD EDIT: Removed Email Address***
because I am new user of this site and don't even know how to see reply of asked question.

I'll be your highly obliged.

Thanks in advance...

This post has been edited by JackOfAllTrades: 26 November 2010 - 08:38 AM


Is This A Good Question/Topic? 0
  • +

Replies To: creating/opening new tab in our simple web browser in c#

#2 Sergio Tapia  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1252
  • View blog
  • Posts: 4,168
  • Joined: 27-January 10

Re: creating/opening new tab in our simple web browser in c#

Posted 26 November 2010 - 08:34 AM

Sorry, we aren't a code writing service. Show what you've tried, what is giving you exceptions, etc. We won't just hand you code.

Kind warm regards,
Prince Abdula Fajula Falafel.
Was This Post Helpful? 0
  • +
  • -

#3 SourLemons  Icon User is offline

  • D.I.C Head

Reputation: 4
  • View blog
  • Posts: 65
  • Joined: 02-August 10

Re: creating/opening new tab in our simple web browser in c#

Posted 26 November 2010 - 05:49 PM

Tab control is a basic feature in any programming languages.

Steps :

* You are going to add a new tabControl in your form.

* If it's a web browser, your "New Tab" option will likely to be under file menu. (For eg. File > New Tab.)

* In all the add New Tab options/ buttons add this code :

        private void toolStripButton1_Click(object sender, EventArgs e)
        {            
               TabPage newPage = new TabPage("New Page");
               tabControl1.TabPages.Add(newPage);            
               RichTextBox rtb = new RichTextBox();            
               rtb.Dock = DockStyle.Fill;            
               newPage.Controls.Add(rtb);        
       }



* In all the remove Tab options/buttons add this code :

   private void removeToolStripMenuItem_Click(object sender, EventArgs e)
        {
            tabControl1.TabPages.Remove(tabControl1.SelectedTab);
        }




* That's all. Although I am a beginner i can teach you what i know.

* But you shouldn't have posted your email address to send the code on.

Happy Learning.
Was This Post Helpful? 0
  • +
  • -

#4 Gorian  Icon User is offline

  • ninja DIC
  • member icon

Reputation: 120
  • View blog
  • Posts: 1,681
  • Joined: 28-June 08

Re: creating/opening new tab in our simple web browser in c#

Posted 26 November 2010 - 05:57 PM

Man, you just made everything posted by Prince Abdula Fajula Falafel mean nothing. Don't give him any code until he posts his efforts.
Was This Post Helpful? 0
  • +
  • -

#5 SourLemons  Icon User is offline

  • D.I.C Head

Reputation: 4
  • View blog
  • Posts: 65
  • Joined: 02-August 10

Re: creating/opening new tab in our simple web browser in c#

Posted 26 November 2010 - 06:15 PM

What if he didn't even know the codes?

_ You gonna wait for him to post the codes?

Quote

Man, you just made everything posted by Prince Abdula Fajula Falafel mean nothing. Don't give him any code until he posts his efforts.


* I am not giving him any codes. I am just sharing what i know with fellow mate.

Ty.
Was This Post Helpful? 0
  • +
  • -

#6 samforever1989  Icon User is offline

  • D.I.C Head

Reputation: -6
  • View blog
  • Posts: 53
  • Joined: 25-November 10

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 07:56 AM

that was useful buddy but that was not i was trying to know...
I tell you, you must have used mozilla firefox or latest version internet explorer.
in mozilla firefox you can add new tab to the browser or simply use the shortcut key CTRL + D..
I was talking about this new tab not that..
If you could please tell me about this... it would be your greatness...
my email ID is -> ************ and second email id is: -> ******************

and if you dont mind please add me on gtalk or facebook....
my facebook id is *************** and my name is ********** and my living location is Noida (India)

Thankzz for your support...

This post has been edited by JackOfAllTrades: 27 November 2010 - 08:42 AM
Reason for edit:: Removed abundant contact info. Keep it to the forums.

Was This Post Helpful? 0
  • +
  • -

#7 Sergio Tapia  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1252
  • View blog
  • Posts: 4,168
  • Joined: 27-January 10

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 08:42 AM

We don't send emails outside of the forums. People can benefit from shared information here.

What you want is fire a keyboard command, right?
Was This Post Helpful? 0
  • +
  • -

#8 samforever1989  Icon User is offline

  • D.I.C Head

Reputation: -6
  • View blog
  • Posts: 53
  • Joined: 25-November 10

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 09:47 AM

firing keyboard command is lateral thing my friend I am just asking about opening new tab as we open in mozilla firefox...by clicking + button ..... if you dont mind you just open the mozilla firefox and try to open any website in other tab by clicking + button or simply firing shortcut CTRL + D

waiting for your reply....
thankzz....
Was This Post Helpful? 0
  • +
  • -

#9 Sergio Tapia  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1252
  • View blog
  • Posts: 4,168
  • Joined: 27-January 10

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 10:05 AM

I have no idea what the hell you're talking about. I'm out!
Was This Post Helpful? 0
  • +
  • -

#10 Amrykid  Icon User is offline

  • 4+1=Moo
  • member icon

Reputation: 148
  • View blog
  • Posts: 1,589
  • Joined: 16-December 08

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 10:22 AM

View Postsamforever1989, on 27 November 2010 - 09:47 AM, said:

firing keyboard command is lateral thing my friend I am just asking about opening new tab as we open in mozilla firefox...by clicking + button ..... if you dont mind you just open the mozilla firefox and try to open any website in other tab by clicking + button or simply firing shortcut CTRL + D

waiting for your reply....
thankzz....


You want to add a new 'Browser Tab' when the user presses CTRL + T? Am I correct? If so, just handle the Form's KeyUp event.
Was This Post Helpful? 0
  • +
  • -

#11 SourLemons  Icon User is offline

  • D.I.C Head

Reputation: 4
  • View blog
  • Posts: 65
  • Joined: 02-August 10

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 11:09 AM

I didn't really understand what you wanted us to do for you.

It seems to be about keystrokes so.

Suppose you have a button like that.

Posted Image

You wanna add a keystroke on the File > New.

Then click on the button ( New in this case ), Take your eyes to Properties.

You'll get this kind of option where you can set which and what kind of keystroke do you want.

Posted Image

So, that's set.

_ Everything i gave u until now belongs to AmryKid. *Credits to him.

( A piece of note for you : )
Spoiler

Was This Post Helpful? 0
  • +
  • -

#12 tlhIn`toq  Icon User is offline

  • Please show what you have already tried when asking a question.
  • member icon

Reputation: 5417
  • View blog
  • Posts: 11,608
  • Joined: 02-June 10

Re: creating/opening new tab in our simple web browser in c#

Posted 27 November 2010 - 07:19 PM

Quote

Could you please tell me how can we add feature of opening new tabs


As you were told earlier: You need to use a TabControl. Then you make new TabPage and add the TabPage to the TabControl.TabPages collection

 and viewing history.

Each time the user goes to a new page, add the page URL to a List<string>
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1