BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 06-01-2009, 03:05 PM   #1 (permalink)
Knows Where the Search Button Is
 
Join Date: Dec 2008
Model: 8800
PIN: N/A
Carrier: O2
Posts: 15
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default how to use FileConnection

Please Login to Remove!

I am trying to access a text file on my hard disk while working on the BB JDE and using the 8800 simulator. I am using the following code but i get the exception that the file does not exist.

PHP Code:
FileConnection filecon = (FileConnection
Connector.open"file:///SDCard/Blackberry/test.txt"); 
The file is located in the same folder as my project.
Is the filepath correct?

Thanks in advance
Offline  
Old 06-01-2009, 07:41 PM   #2 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

That code will only access the simulated SDCard for the simulator. Have a look at this KB article: How To - Use a computer file system as a microSD card
__________________
My other Blackberry is a PlayBook.
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.