Skip to content

Commit 8c55a3b

Browse files
authored
kb(pivotgrid): update methods in example
1 parent 3ab1832 commit 8c55a3b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

knowledge-base/pivotgrid-update-old-persisted-filter-states-after-security-update.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ private string GetConvertedState(string oldState)
150150
private string GetFileContents(string filePath)
151151
{
152152
string contents;
153-
using (var stream = new FileStream(filePath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite))
153+
using (var stream = new FileStream(Server.MapPath(filePath), FileMode.Open, FileAccess.Read, FileShare.ReadWrite))
154154
using (var reader = new StreamReader(stream))
155155
{
156156
contents = reader.ReadToEnd();
@@ -182,7 +182,7 @@ End Function
182182

183183
Private Function GetFileContents(filePath As String) As String
184184
Dim contents As String
185-
Using stream As New FileStream(filePath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite)
185+
Using stream As New FileStream(Server.MapPath(filePath), FileMode.Open, FileAccess.Read, FileShare.ReadWrite)
186186
Using reader As New StreamReader(stream)
187187
contents = reader.ReadToEnd()
188188
End Using

0 commit comments

Comments
 (0)