Possible to open partial view from an href?

  1. #1

    Possible to open partial view from an href?

    Hi, I know how we can fire partial views from buttons, and other such ext controls (using url.action), but I need to know if I can fire one from an href tag. I'm trying to implement a link in the header of a panel for a user to view specific information. I have the partial view defined and in the Shared folder, and I have the ActionResult Controller method defined. I know that they are setup correctly since I can get it to fire on tying the event to a button outside of the header. I'm not really including much code since the question is generic and really irrelevant to what I'm trying to display.

    If it is not possible, is there a way to embed a linkbutton in the header along with the text?

    Below you can see what I'm trying to do. Any thoughts on how to achieve this?

                                        Html.X().GridPanel()
                                            .ID("gridUserBusinessUnits")
                                            .HideHeaders(false)
                                            .EmptyText("There are no business units to take action on.")
                                            .Width(470)
                                            .Height(175)
                                            .Border(true)
                                            .Frame(false)
                                            .Title(String.Format("Business Units - (<a href = '{0}NRE/Coordinator/ApproveUsers_ViewApprovedBusinessUnits'>View Approved Business Units</a>)", (String)ViewBag.BaseURL))
    Thanks for any help you guys can provide!
  2. #2
    So, you need to know how to execute javascript after clicking on anchor tag?
    If yes then see the following link
    http://stackoverflow.com/questions/5...f-href-in-html
  3. #3
    Wow... I completely forgot that I could call the method from javascript since I'm so accustomed to tying them to the DirectEvents. Sorry for my temporary memory loss. Haha. Thanks for getting back to me. Please mark this as closed.

Similar Threads

  1. Replies: 17
    Last Post: Apr 27, 2016, 1:22 AM
  2. [CLOSED] [#549] Rendering Partial View Error
    By LAEUser in forum 2.x Legacy Premium Help
    Replies: 9
    Last Post: Oct 01, 2014, 12:36 PM
  3. Replies: 3
    Last Post: Dec 02, 2013, 1:01 PM
  4. [CLOSED] Partial View
    By PriceRightHTML5team in forum 2.x Legacy Premium Help
    Replies: 9
    Last Post: Jul 16, 2013, 1:16 PM
  5. bind to grid view with <a href>
    By dx7 in forum 2.x Help
    Replies: 2
    Last Post: Oct 23, 2012, 9:02 AM

Tags for this Thread

Posting Permissions