C# - How To Convert A Folder To Zip File
Feb 17, 2011What is the best way to convert a whole folder (including it's contents) into a .zip file?
View 4 RepliesWhat is the best way to convert a whole folder (including it's contents) into a .zip file?
View 4 RepliesI have requirement to copy or move file from webserver app folder to local file system folder (user selected). How is it possible in ASP.Net.
On my page i have textbox and browse button and user clicks browse button to select folder and there is Copy/Move button and when clicked the files under webserver folder should be move to the user selected folder. The webserver folder path is available to application.
I am working on asp.net 3.5 in C#. In my application I have to Create folder and upload file in that folder, which works fine on my machine. I want help for create folder and upload file in that folder on other machine which is connected in LAN. code for create folder and Upload file on my machine
string FileName = FileUpload1.FileName;
I am ristrcting access to the Account folder using below:
<location path="Account">
<system.web>
<authorization>
<deny users="?"/>
<allow users="*"/>
</authorization>
</system.web>
</location>
and access to the Default.aspx using
<location path="Default.aspx">
<system.web>
<authorization>
<deny users="?"/>
<allow users="*"/>
</authorization>
</system.web>
</location>
but how do i restrict access to a specific file in the Account folder rather than the entire folder?
I tried the following but did not work
<location path="AccountChangePassword.aspx">
<system.web>
<authorization>
<deny users="?"/>
<allow users="*"/>
</authorization>
</system.web>
</location>
When we select pull down menu Build -> Publish .... website. The cs extension file dropped into bin folder instead of root folder.
View 2 RepliesI would like ask you for some ideas how can I write mechanism that will be automatically read files from folder. I don't know how to schedule the write task. I want to check for new file everyday and if the new file is in the folder read it.
View 2 Replieshow to move a file from a folder to another folder in asp.net? I have the filename as a string and the directory to copy to there is a saveas command but i cant use it with a string.
.SaveAs(Server.MapPath("folder/" & myfile))
Is there any control which has to browse folder path alone instead of selecting folder path + file ?any server side or client side control ?
View 1 RepliesI have to copy a file from client machine to server folder without use file upload control.
i tried with WebClient().Like this
Dim onbjweb As New WebClient()
onbjweb.UploadFile(Server.MapPath(serverpath), "POST", LocalFilePath).
Its working fine in localhost.When its deployed in server its not working.
I need to save a file into special folder.
if (TextBox1.Text == s)
{ MessageBoxResult mbr = MessageBox.Show(this, "Do you want to save file?", "saved", MessageBoxButton.YesNoCancel); // if (mbr == MessageBoxResult.Yes) // { // //string path = string.Empty; // string path; // path = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "abcFile"; // if (!Directory.Exists(path)) // Directory.CreateDirectory(path); // }
It creates a folder abc if it doen't exist, i need to save s where s is a textfile.
I have a file uploader I would like to be able to have a folder added to the folder path on upload based on a textbox.text "MapPath("~/Uploads/" + Path.GetFileName(e.filename))"
I have Dim folder as String = textbox.text how do I add folder to MapPath("~/Uploads/"
it currently checks for .xml files how can I add more .doc .gif etc
Dim savePath As String = MapPath("~/Uploads/" + Path.GetFileName(e.filename)) 'Validation for file extension If Path.GetExtension(e.filename).Contains(".xml") Then Return End If
I want example upload pdf file and send name, title, filename, filepath to database and retrieve and display pdf from Upload Folder...
View 1 RepliesI wish to know how to convert the byte array file to a file in a string format and display it in a webpage. how can i perform this?
View 1 RepliesMy files are stored on a data repository in different formats like .doc,.docx,.pdf,.jpeg,.jpg,.tiff. I want to get those files in binary format(i.e byte[]) so that I can able to see that file to the user using a radbinary image control.I am able to get .jpeg and .jpg files and I can show those to users.But while I am trying to show .doc,.docx,.pdf files I am getting "Not valid parameter" exception.How can I solve this problem? My doubt is that pdf,doc,docx files are having no of pages. So while converting this total pages in to binary data I am getting error. So How can I show first page of .doc,.docx,.pdf files using radbinary image control.Here is my code.RadBinary Image controlis a telerik control,it only deals with binary data.
[Code]....
I have developed one webApplication that i suppose to submit to my client but for security reason i want to convert all the .cs to dll file.example consider customer.aspx customer.aspx.cs here i donot want to provide customer.aspx.cs file to customer instead i want to give client as dll fileI i can do this, PLEASE HELP ME, IT IS VERY URGENT FOR ME, I WAS TRYED LAST 2 DAYS,
View 5 RepliesI need to convert a excel file to pdf file in asp.net. How to achieve this in c#.
View 1 Repliessend me code to convert html file into pdf file using asp.net
View 4 RepliesIs there a way I can convert a Powerpoint file to a Flash file using an SDK or any other method?
View 3 Replieshow to convert pdf file to image file?
View 1 RepliesI want to upload files to the web servers from the client machines.
Can i upload a file on a network share folder using file upload control?
I would like to create a share folder on a file server sitting next to the web server. If i upload the file from the network share folder instead of uploading it from the client machine does it make any difference?
Will the file be stored in a temporary location before copying to the final destination? Where will be the file stored in this case of uploading it from share folder?
I have seen code samples on this all over and I am not sure which is a more secure way to do this. I just want to be able to retreive a file from one of the folders in my website and display it in a tag(Programatically at page load). If you can plese use C#.
View 7 RepliesI really try to find on google how can we convert .doc and .txt file into pdf file butnot getting required answer or code.I want any command line software of converter code which will provide code that convert above to format file into pdf file. if any user upload upload .txt and .doc file then it will be convert into .pdf file in my application.so need coversion code.and after coverting into pdf when i clicked on it. it will be open into pdf in browser.
View 2 Replieshow to convert the cs (example.cs) file to ascx (example.ascx) file. i don't know how to convert the file .I am novice of asp.net. i want to all the steps to convert ascx file.
View 3 RepliesI am using VSTS 2008 + C# + .Net 3.5 + ASP.Net + IIS 7.0 to develop web application. I want to convert html file/page/string into PDF file.
Any built-in solution from Microsoft to do this? The top issue is about paging, i.e. how to map html conent to converted PDF page? e.g. I want to display an html table and an image in page 1 of converted PDF file, and display following html text after the image in original html into page 2 of converted PDF file?
I am Using C# asp.net 2008, my requirement is i want to convert HTML file to PDF File..
Ex:
I will upload (.html or .htm) file, then i will click convert then it should ask Open/ Save/Cancel as PDF File.
i gone through various search, but available sources are Licensed product, trial version like tat only send me sample source code...