Answered by:
Newbie in need of help

Question
-
Hey guys im very new at c# and want to learn
Ok i have 2 questions for now
1) How can i make a box that will expand when clicked on to show and unshow a list of items underneath that can then be links them selves.
2) Can someone explain how i can make a simple file upload system that will require a zip file to be uploaded to a website.
Thanks guysSaturday, September 27, 2008 11:54 PM
Answers
-
Create a form with one button and some lables on button_click event you can set lables visible property true or flase.here is a code to upload a file
public form1() { InitializeComponent();
//only binary is uploaded this is more safe
System.Net.WebClient Client = new WebClient(); //creat a new object of webclient Client.UploadFile("http://localhost/myPage.aspx, "c:\wesiteFiles\newfile.aspx");
}
Sunday, September 28, 2008 12:31 AM
All replies
-
Create a form with one button and some lables on button_click event you can set lables visible property true or flase.here is a code to upload a file
public form1() { InitializeComponent();
//only binary is uploaded this is more safe
System.Net.WebClient Client = new WebClient(); //creat a new object of webclient Client.UploadFile("http://localhost/myPage.aspx, "c:\wesiteFiles\newfile.aspx");
}
Sunday, September 28, 2008 12:31 AM -
thanks so much but how would i use that code to set it so that a button will submit the file from a textbox with the link to the file.
Sunday, September 28, 2008 12:33 AM -
if it has been helpful please mark it as helpful or answeredSunday, September 28, 2008 12:35 AM
-
Starting out, the best thing to do is just to play around, read online tutorials for C#, etc to get experienced with the basics. I know, I know, it's extremely boring and all that, but having a solid knoweldge base of the language and obviously programming languages in general really helps when trying to figure out how to do something that you don't know how to do.
Thanks,
paoloTheCool
Sunday, September 28, 2008 3:10 AM