Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Contributor
Posts: 41
Registered: ‎04-24-2012
My Device: storm
My Carrier: blackberry

System.in in blackberry java

hi im trying to port a app from andriod to blackberry java in 1 part of the app it gets input from the server and put it in a System.in.read() method but when i looked at the api there is no System.in in the system class is there any substitute for it in blackberry java?

Developer
Posts: 1,807
Registered: ‎04-28-2009
My Device: Z10 (STL100-4)-10.3.2.858, Z10 (STL100-3)-10.3.1.2576, Z30 (STA100-5)-10.3.1.2582, Passport (SQW100-1)-10.3.1.2576, PlayBook (16GB)-2.1.0.1917
My Carrier: Verizon

Re: System.in in blackberry java

You put data "in" to System.in? System.in is to read data "out".
---Spends time in #blackberrydev on freenode (IRC)----
Three simple rules:
1. Please use the search bar before making new posts.
2. "Like" posts that you find helpful.
3. If a solution has been found for your post, mark it as solved.
--I code too much. Well, too bad.
Developer
Posts: 16,997
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: System.in in blackberry java

to receive data from a server you open an inputstream, for example on an httpconnection.
check the httpdemo and other samples to see that in the field.

I suggest to read it with this method:
http://www.blackberry.com/developers/docs/7.1.0api/net/rim/device/api/io/IOUtilities.html#streamToBy...
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter