Modal message issue

Peter_1985 2,691 Reputation points
2021-09-25T07:01:35.217+00:00

Hi,
Where to put Modal title below?

                    Page.ClientScript.RegisterStartupScript(this.GetType(), "alert", "ShowMessage('My message');", true);    

How to remove Save changes button below?

135183-6b.png

ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
3,541 questions
0 comments No comments
{count} votes

Accepted answer
  1. Yijing Sun-MSFT 7,086 Reputation points
    2021-09-27T04:16:04.537+00:00

    Hi @Peter_1985 ,
    How do you write your modal? If you used bootstrap modal or jquery modal,you could remove the save button.Just like this:

     <div class="modal fade" id="exampleModal" tabindex="-1" role="dialog"  
                    aria-labelledby="myModalLabel" aria-hidden="true">  
                    <div class="modal-dialog">  
                        <div class="modal-content">  
                            <div class="modal-header">  
                                <button type="button" class="close"  
                                    data-dismiss="modal" aria-hidden="true">  
                                    &times;  
                                </button>  
                                <h4 class="modal-title" id="myModalLabel">title  
                                </h4>  
                            </div>  
                            <div class="modal-body">  
                              
                            </div>  
                            <div class="modal-footer">  
                                <button type="button" class="btn btn-default"  
                                    data-dismiss="modal">  
                                    close  
                                </button>  
      
                                //remove this button  
                                <button type="button" class="btn btn-primary">  
                                    save  
                                </button>  
                            </div>  
                        </div>  
                        <!-- /.modal-content -->  
                    </div>  
                </div>  
    

    Best regards,
    Yijing Sun


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our  documentation  to enable e-mail notifications if you want to receive the related email notification for this thread.


1 additional answer

Sort by: Most helpful
  1. Peter_1985 2,691 Reputation points
    2021-09-29T10:18:19.433+00:00

    Please see the code within css file below. Yes, I expect OK button to be centered within the Modal. Where to adjust it?
    136210-6e.png


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.