dear all
i have a hyper link to download a pdf document, the user click the link the save as dialog open
how can i do this ?
i try to put the path of the file in the hyper link but nothing happend .
thanks
dear all
i have a hyper link to download a pdf document, the user click the link the save as dialog open
how can i do this ?
i try to put the path of the file in the hyper link but nothing happend .
thanks
ما يحدث هو ما يلي... عند النقر على الرابط الذي يشير إلى ملف الـ PDF يتم فتح هذا الملف ضمن برنامج الـ Acropat الوجود على جهازك لذلك لا يظهر صندوق الحوار الذي يطلب منك حفظ أو فتح الملف ... هل هناك مشكلة فيما لو وضعت الملف ضمن مجلد zip بدلاً عن ذلك
thanks for reply
i try to do that but also nothing happend ,
when i right click on the link and click the save as it's saved
fofgh كتب:dear all
i have a hyper link to download a pdf document, the user click the link the save as dialog open
how can i do this ?
i try to put the path of the file in the hyper link but nothing happend .
thanks
استعمل الشفرة التالية التي صنعتا وسوف تعمل على تنزيل الملف
Dim objFile As System.IO.FileInfo
objFile = New System.IO.FileInfo(Server.MapPath("~/file.pdf"))
Response.Clear()
Response.AddHeader("Content-Length", objFile.Length.ToString())
Response.AddHeader("Content-Disposition", "attachment;filename=file.pdf")
Response.AddHeader("Content-Length", objFile.Length.ToString())
Response.ContentType = "application/octet-stream"
Response.WriteFile(objFile.FullName)
Response.Flush()
Response.End()اقتباسمساحة تبدأ من 2000 ميجا بايت بسعر 1.99 دولار شهريا.ا
اقتباسASP.NET 1.1-2.0-3.0-3.5-4.0-4.5.1 / MVC ASP.NET / PHP 5.x / ColdFusion / MSSQL 2008 & 2012 / MYSQL
i'll try it thanks
هذا الموضوع مغلق.