开发者

How to upload a CSV file and and read it's data in the client side itself and send the data as a stream through a ajax post?

I need to upload a CSV file and get its contents form the client side itself. Then post it to the server where I can retriev the stream and do the string manipulations in the serer action methods. Is there any jquery plugin for this task to upload a csv file and send 开发者_Go百科data as a stream using ajax or jason? I am really new to this area.I am working in VS2010 AND mvc3.

Can some one give me a clear solution for this mater?? Any examples?? I did search a lot but did not find any suitable solution yet. Can anyone please help me with this matter. Thanks so much.


In your action method you can do something like:

public ActionResult ProcessFile(HttpPostedFileBase uploadedFile){
Stream stream = uploadedFile.InputStream;

// Do something with the data

}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜