i have used below code for downloading efile , but i have problem invalid arguments in function download(Efile).
please help what is the problem.
protected void LinkButton1_Command(object sender, CommandEventArgs e)
{
if (e.CommandName == "Download")
{
_DataContext = new EDMSDataContext();
//you can get your command argument values as follows
string FileId = e.CommandArgument.ToString();
int _FileId = Convert.ToInt32(FileId);
var Efile = from ef in _DataContext.tblFiles
where ef.FileId == _FileId
select ef;
if (Efile != null)
{
download(Efile);
}}}
private void download ( tblFile Efile)
{
Byte[] bytes = (Byte[])Efile.Data.ToArray();
Response.Buffer = true;
Response.Charset = "";
Response.Ca ...
Go to the complete details ...