Solved

Pop Bootstrap Modal On Load MVC

Posted on 2016-08-23
2
83 Views
Last Modified: 2016-08-24
I use to use this using webforms to pop a modal on load

    Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
        ScriptManager.RegisterStartupScript(Me, [GetType](), "Show Modal Popup", "$('#modalSearch').modal('show');", True)
    End Sub

Open in new window


Can anyone tell me how to do it using MVC
0
Comment
Question by:edjones1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 11

Accepted Solution

by:
louisfr earned 500 total points
ID: 41768284
I would put it in the page directly.
<script type="text/javascript">
    $(function() {
        $('#modalSearch').modal('show');
    });
</script>

Open in new window

0
 

Author Closing Comment

by:edjones1
ID: 41768341
Perfect
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
This article shows how to deploy dynamic backgrounds to computers depending on the aspect ratio of display
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

751 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