BlackBerry Forums Support Community
              

Closed Thread
 
LinkBack Thread Tools
Old 03-26-2010, 01:08 AM   #1 (permalink)
New Member
 
Join Date: Mar 2010
Model: 8110
PIN: N/A
Carrier: vodafone
Posts: 11
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Http Connection

Please Login to Remove!

Hi all,
How to crate http connection in blackberry using j2me api?
Offline  
Old 04-01-2010, 04:33 AM   #2 (permalink)
JZO
New Member
 
JZO's Avatar
 
Join Date: Apr 2010
Model: 9530
PIN: N/A
Carrier: T-Mobile
Posts: 3
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Use the Connection class to create your connection and cast it the appropirate connection class type.

For example:

HttpConnection connection = (HttpConnection)Connector.open("h t t p : / /" + host);

Please remove space chars, this ugly blog engine cannot apply me to post this reply.

In addvise you can create direct TCP socket connection with the same pattern:

"s o c k e t : / /", "h t t p : / /", "s s l : / /", "t l s : / /"

SocketConnection connection =
(SocketConnection)Connector.open("s o c k e t : / /" + host + ":80");

Please remove space chars too, this ugly blog engine cannot apply me to post this reply.
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

QTY = 6 HYUNDAI/HYNIX HY29F800BG-70 8-Megabit (1Mx8/512Kx16) 5V Flash Memory
$12.0
QTY = 6   HYUNDAI/HYNIX HY29F800BG-70 8-Megabit (1Mx8/512Kx16) 5V Flash Memory picture10pcs LED Driver Cycle Flash Controller 3V For 6pcs LEDs
$1.69
10pcs LED Driver Cycle Flash Controller 3V For 6pcs LEDs picture10Pcs WINBOND W25Q80BVSSIG 25Q80BVSIG W25Q80B SOP-8 IC Chips FLASH US
$8.95
10Pcs WINBOND W25Q80BVSSIG 25Q80BVSIG W25Q80B SOP-8 IC Chips FLASH US pictureNortel Call Pilot 100 Voice Mail with Flash Card NTAB9865 Guaranteed
$165.0
Nortel Call Pilot 100 Voice Mail with Flash Card NTAB9865 Guaranteed  picture4Pcs ESP32 ESP-WROOM-32 Wifi Bluetooth Dual-Core CPU Compatible Flash 16Mb US
$30.95
4Pcs ESP32 ESP-WROOM-32 Wifi Bluetooth Dual-Core CPU Compatible Flash 16Mb US picture






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