示例#1
0
        private void databaseListBox_Item_Click(object sender, RoutedEventArgs e)
        {
            String connecting_string = DatabaseStackPanal.selected_database_connecting_string(ServerListbox, databaseListbox);

            connectingsStringLabel.Content = connecting_string;

            return;
        }
示例#2
0
        private void okaybtn_Click(object sender, RoutedEventArgs e)
        {
            String folderPath = projectFolder_label.Content.ToString();

            if (folderPath != null)
            {
                String ReplaceIt = replaceTextbox.Text;
                String ReplaceBy = DatabaseStackPanal.selected_database_connecting_string(ServerListbox, databaseListbox);
                //replace_word_in_file(CurrentWorkingFile, ReplaceIt, ReplaceBy);
                List <string> file_list = find_all_xml_config_file_inDIR(projectFolder_label.Content.ToString());
                replace_string_in_all_file(file_list, ReplaceIt, ReplaceBy);
                MessageBox.Show("successfully Replace");
            }
            else
            {
                MessageBox.Show("Please First Select The Project Folder");
            }

            return;

            /*
             * String CurrentWorkingFile = Properties.Settings.Default.activeFileName;
             * if (!CurrentWorkingFile.Equals("-1"))
             * {
             *  String ReplaceIt = replaceTextbox.Text;
             *  String ReplaceBy = DatabaseStackPanal.selected_database_connecting_string(ServerListbox, databaseListbox);
             *  replace_word_in_file(CurrentWorkingFile, ReplaceIt, ReplaceBy);
             *
             *  MessageBox.Show("successfully Replace");
             * }
             * else
             * {
             *  MessageBox.Show("Sorry, No Active File Found. Please Open File ");
             * }
             * return;
             */
        }