I have a button that I want to have open a dialogue box to select a file and then rename it and save it in a specific directory. I have the following code which opens a dialogue box but it is not setting the pick directory and when I try to save it tries to save in the same directory as the file I picked.
private void attachfileBN_Click(object sender, EventArgs e)
{
SaveFileDialog sfd = new SaveFileDialog();
sfd.ShowDialog();
sfd.InitialDirectory = "C";
sfd.FileName = "//server1/common/estimatedocs/estimatenoTextBox.Text";
}
private void attachfileBN_Click(object sender, EventArgs e)
{
SaveFileDialog sfd = new SaveFileDialog();
sfd.ShowDialog();
sfd.InitialDirectory = "C";
sfd.FileName = "//server1/common/estimatedocs/estimatenoTextBox.Text";
}