确认对话框来自MVC控制器



我想读取excel和计数excel中的行数,并显示用户消息以确认要上传的行数。我只是在寻找帮助如何显示消息从控制器阅读excel计数后。

public ActionResult UploadAccountCreation(FormCollection form)
{
if (Request.Files.Count> 0 || Request.Files[0].ContentLength > 0)
{

// Read Excel Count
// Show Message to user "Are you sure you want to upload X number of account"
if(yes)
{
// Code for yes
}
}
}

你可以像在这篇文章中调用javascript方法来获得警报Yes没有或选项基于你的excel计数。

最新更新