Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Excel - VB

  • 19-06-2008 6:39pm
    #1
    Registered Users, Registered Users 2 Posts: 7,806 ✭✭✭


    There is probably a very simple way of doing this but I dont know how, and can't find it anywhere.

    Im writing macros in excel that perform certain calculations using various books but at a certain point the user will have to enter their own data and this data is obtained at a certain webpage.

    I am trying to put a link ,to said particular webpage, in a message box. So if you click on the link in the msgbox an internet explorer page will open up.

    The other option is to just have this page open up at a particular point within the macro.

    Sorry - Im new to VB!!:o


Comments

  • Registered Users, Registered Users 2 Posts: 2,931 ✭✭✭Ginger


    Just use a confirm box and when the person clicks ok it opens the page.. if they click cancel, it doesnt


  • Registered Users, Registered Users 2 Posts: 7,806 ✭✭✭Raoul


    yeah but you see I dont know how to actually make the page open up. If you know what I mean.

    Like i can put www.google.ie in a msgbox but I cant get it to be a link.

    And I don't know how to make a webpage open in the actual code.


  • Registered Users, Registered Users 2 Posts: 2,931 ✭✭✭Ginger


    In very rough VB
    If Confirm("Do you want to do web site) = vbYes Then
     ActiveWorkbook.FollowHyperlink Address:="http://www.yahoo.com" 
    else
    'Do something else
    End if
    

    Should do ...


  • Registered Users, Registered Users 2 Posts: 7,806 ✭✭✭Raoul


    Ginger wrote: »
    In very rough VB
    If Confirm("Do you want to do web site) = vbYes Then
     ActiveWorkbook.FollowHyperlink Address:="http://www.yahoo.com" 
    else
    'Do something else
    End if
    

    Should do ...


    Yep got that working. THANKS!!


Advertisement