VS 2015 IntelliSense:未预览的异常抛出

时间:2015-08-03 16:41:15

标签: c# xml exception-handling intellisense visual-studio-2015

我刚刚升级到VS 2015企业版,正在使用C#。

在VS 2013中,我能够将XML异常标记添加到我的方法中,当尝试使用该方法时,我会看到可以抛出异常的预览。

然而,在VS 2015中,当我将鼠标悬停在我的方法调用上,或尝试拨打电话时,我无法预览可以抛出的异常。

如何让VS 2015显示方法可以抛出哪些异常?

以下是我的测试课程。

谢谢。

VS 2013

enter image description here

VS 2015

enter image description here

2 个答案:

答案 0 :(得分:2)

您可以使用此类摘要

<form action = "sendmsg.php" method="POST">
            <input type="text" placeholder="Enter subject" name="subject"><br/><br/>
            <textarea style="height:300px;width:450px;" maxlength="50" placeholder="Enter Message" name="message"></textarea><br/><br/>
            <input type="submit" name="submitmsg" value="Send Message"/>
            <?php
            require("dbcon.php");

            if(isset($_POST['submitmsg'])){
                $to = $_GET['id']; 
                $subject = $_POST['subject'];
                $message = $_POST['message'];
                $sql = "INSERT INTO msg VALUES ('','$to','NOW()','$subject','$message')";
                $send = mysqli_query($con, $sql);
                echo "Done";
                echo $to;
            }

答案 1 :(得分:2)

此问题已在Visual Studio 2015 Update 1中得到解决。

您可以下载here

相关问题