Quantcast
Channel: Windows Phone Development » Windows Phone 7 series development
Viewing all articles
Browse latest Browse all 10

WP7 CTP and Beta bug: IsolatedStorageFile.GetFileNames("searchPattern”)

$
0
0

I’ve just stumbled over the method IsolatedStorageFile.GetFileNames(“searchPattern”).

Lets take the given code:

try

            {

IsolatedStorageFile file = IsolatedStorageFile.GetUserStoreForApplication();

 

                file.CreateFile(“test1.txt”).Close();

                file.CreateFile(“test2.txt”).Close();

                file.CreateFile(“test3.txt”).Close();

                file.CreateFile(“test4.txt”).Close();

                file.CreateFile(“test5.txt”).Close();

                file.CreateFile(“leer1.txt”).Close();

                file.CreateFile(“leer2.txt”).Close();

                file.CreateFile(“leer3.txt”).Close();

                file.CreateFile(“leer4.txt”).Close();

                file.CreateFile(“leer5.txt”).Close();

 

string[] files = file.GetFileNames();

                files = file.GetFileNames(“test*.txt”); //Returns 10 entries, instead of 5

 

            }

catch (IsolatedStorageException ios)

            {

            }

 

This shows that GetFileNames with search patterns fails in CTP and current beta returning in the sample with 10 entries, instead of 5.

If you use the sample including a subfolder, the values returned are correct.

 

SO, forr now, beware using this method on the Isolated Storage base folder.

The post WP7 CTP and Beta bug: IsolatedStorageFile.GetFileNames("searchPattern”) appeared first on Windows Phone Development.


Viewing all articles
Browse latest Browse all 10

Trending Articles


Vimeo 10.7.1 by Vimeo.com, Inc.


UPDATE SC IDOL: TWO BECOME ONE


KASAMBAHAY BILL IN THE HOUSE


Girasoles para colorear


Presence Quotes – Positive Quotes


EASY COME, EASY GO


Love with Heart Breaking Quotes


Re:Mutton Pies (lleechef)


Ka longiing longsem kaba skhem bad kaba khlain ka pynlong kein ia ka...


Vimeo 10.7.0 by Vimeo.com, Inc.


FORECLOSURE OF REAL ESTATE MORTGAGE


FORTUITOUS EVENT


Pokemon para colorear


Sapos para colorear


Smile Quotes


Letting Go Quotes


Love Song lyrics that marks your Heart


RE: Mutton Pies (frankie241)


Hato lada ym dei namar ka jingpyrshah jong U JJM Nichols Roy (Bah Joy) ngin...


Long Distance Relationship Tagalog Love Quotes