Skip to content

Commit 29b5854

Browse files
committed
Added File_Move and File_Replace article
1 parent b928a99 commit 29b5854

3 files changed

Lines changed: 27 additions & 1 deletion

File tree

docs2/pages/documentations/file/file-move.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ File_Move
1616
## Example
1717

1818
```csharp
19-
EXEC File_Move @sourceFileName = 'C:\Temp\MyTest.txt', @destFileName = 'C:\Temp\MyTest.txt'
19+
EXEC File_Move @sourceFileName = 'C:\Temp\MyTest.txt', @destFileName = 'C:\Temp\MyNewTest.txt'
2020
```
2121

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# File_Replace
2+
3+
`File_Replace` replaces the contents of a specified file with the contents of another file, deleting the original file, and creating a backup of the replaced file and optionally ignores merge errors.
4+
5+
```csharp
6+
File_Replace
7+
@sourceFileName NVARCHAR (MAX),
8+
@destFileName NVARCHAR (MAX),
9+
@destBackupFileName NVARCHAR (MAX),
10+
@ignoreMetadataErrors BIT
11+
```
12+
13+
## Parameters
14+
15+
- **sourceFileName**: The name of a file that replaces the file specified by `destinationFileName`.
16+
- **destFileName**: The name of the file being replaced.
17+
- **destBackupFileName**: The name of the backup file.
18+
- **ignoreMetadataErrors**: `true` to ignore merge errors (such as attributes and access control lists (ACLs)) from the replaced file to the replacement file; otherwise, `false`.
19+
20+
## Example
21+
22+
```csharp
23+
EXEC File_Replace @sourceFileName = 'C:\Temp\MyTest.txt', @destFileName = 'C:\Temp\MyNewTest.txt', @destBackupFileName = 'C:\Temp\MybackupTest.txt', @ignoreMetadataErrors = 0
24+
```
25+

docs2/pages/documentations/file/file.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ Provides methods for the creation, copying, deletion, moving, and opening of a s
1919
| [File_IsExists(path)](/file-isexists) | Determines whether the specified file exists. | [Try it]()|
2020
| [File_Move(sourceFileName, destFileName)](/file-move) | Moves a specified file to a new location, providing the option to specify a new file name. | [Try it]()|
2121
| [File_ReadAllText(path)](/file-move) | Opens a text file, reads and returns all the text in the file, and then closes the file. | [Try it]()|
22+
| [File_Replace(sourceFileName, destFileName, destBackupFileName, ignoreMetadataErrors)](/file-replace) | Replaces the contents of a specified file with the contents of another file, deleting the original file, and creating a backup of the replaced file and optionally ignores merge errors. | [Try it]()|

0 commit comments

Comments
 (0)