I have a class that contains the following method (The Class name is ZipLoad):
private string DOit(string uName, string pWord) { DOSTUFF..... return "Successfull"; } Now I want pass parameters to the class using my program but there are two parameters. If there was one parameter i would simply do this:
private string testUser; public string getSetUser { get { return testUser; } set { testUser= DOit(value); } } And then use my Windows Forms Application to pass the parameters.
ZipLoad myZipLoad = new ZipLoad(); string report; myZipLoad.testUser = "userName"; report= myZipLoad.getSetUser; My Question is that how do I pass parameters to the DOit method using public properties in the class. One way is to make the method public but for some reason people say that is bad.
Any help would be appreciated ... Thank You