472,338 Members | 1,654 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,338 software developers and data experts.

Isolated Storage Space in Internet Permission Set

Exactly what is the size limit of Isolated Storage in the Internet
permission set?

I have a document indicating it is 10MB
(http://msdn.microsoft.com/msdnmag/is...tSmartClients/)

There is another document indicating it is 10240 in size
(http://msdn.microsoft.com/library/de...-us/cpguide/ht
ml/cpcondefaultsecuritypolicy.asp)

After running a test to create a directory and an empty file in Isolated
Storate under the Internet permission set, I have found the current size to
be 2048 (sample code at the bottom of this message). This would indicate
that the size is 10Kb in size.

Are my findings correct? If so, is there a way to increase the Isolated
Storage quota under the Internet permissions?

Thanks,
Jody
Sample Code
--------------
Private Sub DetermineCache()

Dim isoStore As IsolatedStorage.IsolatedStorageFile

Try

isoStore = IsolatedStorage.IsolatedStorageFile.GetUserStoreFo rDomain()

CreateDir("Test", isoStore)

MsgBox("Max size: " & isoStore.MaximumSize.ToString & ControlChars.CrLf & _

"Current size: " & isoStore.CurrentSize.ToString)

Catch ex As Exception

MsgBox(ex.ToString)

Finally

If Not isoStore Is Nothing Then

isoStore.Close()

isoStore.Dispose()

isoStore = Nothing

End If

End Try

End Sub

Private Function CreateFile(ByVal p_strIsoPath As String, ByVal p_isoStore
As IsolatedStorage.IsolatedStorageFile) As
IsolatedStorage.IsolatedStorageFileStream

Dim isoFile As IsolatedStorage.IsolatedStorageFileStream

Try

isoFile = New IsolatedStorage.IsolatedStorageFileStream(p_strIso Path,
IO.FileMode.Create, IO.FileAccess.ReadWrite, p_isoStore)

Catch ex As Exception

MsgBox(ex.ToString)

Finally

End Try

Return isoFile

End Function

Private Function CreateDir(ByVal p_strPath As String, ByVal p_isoStore As
IsolatedStorage.IsolatedStorageFile) As Boolean

'checks if directory exists in isostorage, creates it if not

Dim bolReturn As Boolean

Dim astrDir() As String

Try

astrDir = p_isoStore.GetDirectoryNames(p_strPath)

If astrDir.Length = 0 Then

p_isoStore.CreateDirectory(p_strPath)

End If

bolReturn = True

Catch ex As Exception

bolReturn = False

End Try

Return bolReturn

End Function
Jul 21 '05 #1
1 2364
Jody -
yes, it is 10240 bytes for Internet by default. You can actually see it if
you look at the Internet named permission set in the security policy in the
".NET Framework Configuration" tool (from the control panel) or by running
"caspol -l" in the command line.
You can change that by creating a new permission set (or modifying the
existing Internet permission set), changing the quota value in the
IsolatedStorageFilePermission there and assigning it to the code group
corresponding to the Inernet zone. This can be done using the tools
mentioned above.
--Ivan
http://blogs.dotnetthis.com/ivan
http://www.dotnetthis.com
This posting is provided "AS IS" with no warranties, and confers no rights.
"Jody Gelowitz" <jo**@mail.visualstatement.com> wrote in message
news:OE**************@tk2msftngp13.phx.gbl...
Exactly what is the size limit of Isolated Storage in the Internet
permission set?

I have a document indicating it is 10MB
(http://msdn.microsoft.com/msdnmag/is...tSmartClients/)

There is another document indicating it is 10240 in size
(http://msdn.microsoft.com/library/de...-us/cpguide/ht ml/cpcondefaultsecuritypolicy.asp)

After running a test to create a directory and an empty file in Isolated
Storate under the Internet permission set, I have found the current size to be 2048 (sample code at the bottom of this message). This would indicate
that the size is 10Kb in size.

Are my findings correct? If so, is there a way to increase the Isolated
Storage quota under the Internet permissions?

Thanks,
Jody
Sample Code
--------------
Private Sub DetermineCache()

Dim isoStore As IsolatedStorage.IsolatedStorageFile

Try

isoStore = IsolatedStorage.IsolatedStorageFile.GetUserStoreFo rDomain()

CreateDir("Test", isoStore)

MsgBox("Max size: " & isoStore.MaximumSize.ToString & ControlChars.CrLf & _
"Current size: " & isoStore.CurrentSize.ToString)

Catch ex As Exception

MsgBox(ex.ToString)

Finally

If Not isoStore Is Nothing Then

isoStore.Close()

isoStore.Dispose()

isoStore = Nothing

End If

End Try

End Sub

Private Function CreateFile(ByVal p_strIsoPath As String, ByVal p_isoStore
As IsolatedStorage.IsolatedStorageFile) As
IsolatedStorage.IsolatedStorageFileStream

Dim isoFile As IsolatedStorage.IsolatedStorageFileStream

Try

isoFile = New IsolatedStorage.IsolatedStorageFileStream(p_strIso Path,
IO.FileMode.Create, IO.FileAccess.ReadWrite, p_isoStore)

Catch ex As Exception

MsgBox(ex.ToString)

Finally

End Try

Return isoFile

End Function

Private Function CreateDir(ByVal p_strPath As String, ByVal p_isoStore As
IsolatedStorage.IsolatedStorageFile) As Boolean

'checks if directory exists in isostorage, creates it if not

Dim bolReturn As Boolean

Dim astrDir() As String

Try

astrDir = p_isoStore.GetDirectoryNames(p_strPath)

If astrDir.Length = 0 Then

p_isoStore.CreateDirectory(p_strPath)

End If

bolReturn = True

Catch ex As Exception

bolReturn = False

End Try

Return bolReturn

End Function

Jul 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Namratha Shah \(Nasha\) | last post by:
Hey Group, After a long week end I am back again. Its nice and refreshing after a short vacation so lets get started with .NET once again. ...
1
by: Jody Gelowitz | last post by:
Exactly what is the size limit of Isolated Storage in the Internet permission set? I have a document indicating it is 10MB...
3
by: U.C. | last post by:
Hello, My client needs to collect data on a disconnected computer. I am hoping I could store data in Isolated Storage as XML files and expose...
2
by: Bexm | last post by:
Hello I am running and asp.net web app and have this line of code: IsolatedStorageFile.GetUserStoreForAssembly(); When it is run I get...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: CD Tom | last post by:
This happens in runtime 2013 and 2016. When a report is run and then closed a toolbar shows up and the only way to get it to go away is to right...
0
by: CD Tom | last post by:
This only shows up in access runtime. When a user select a report from my report menu when they close the report they get a menu I've called Add-ins...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.