Home > Net >  Vs2017 breakpoint suddenly disconnected
Vs2017 breakpoint suddenly disconnected

Time:03-09

RT in debugging the.net core2.1 + layui upload file, the program abruptly, tried a few times still so, what is all this reason, the following is a code
 

Upload files & lt;/button>




<script SRC="https://bbs.csdn.net/topics/~/lib/layui/layui.js" & gt; </script>
Layui. Use ([' upload ', 'table', 'form', 'layer'], function () {
Var $=layui jquery,
The upload=layui. Upload,
Layer=layui layer,
Form=layui. Form;

The upload. Render ({
Elem: '# btnUpload'
, the url: '@ url. The Action (" UploadFile ")'//upload interface
, the accept: 'file'//normal file
//, acceptMime: 'application/VND. - ms excel, application/VND. Openxmlformats - officedocument. Spreadsheetml. Sheet'
XLS, exts: '| XLSX'//is only allowed to upload excel file
, before: function (obj) {
Layer. MSG (' file on the cross... '{
Icon: 16,
Shade: 0.01,
Time: 0
})
}
, done: function (res) {
If (res) code=="0") {
Layer. The MSG (' upload success);
} the else
{
Layer. MSG (res. Message);
}
The console. The log (res)
}
});
});

</script>

 
Public JsonResult UploadFile ()
{
Var f=Request. Form. Files [0].

Return new JsonResult (new {message="uploaded successfully", code="0"});
}

CodePudding user response:

Very strange, I have closed all the browser, can enter the endpoint, vs didn't also terminated, opened a few pages later, after entering the endpoint vs immediately terminate the ~ ~ ~ ~
Anyone know the reason?

CodePudding user response:

The front, do not understand,
  •  Tags:  
  • C#
  • Related