I want to import facebook libraries for blackberry 5.0 and above and don't want to import those libraries for 4.6 and 4.7.
I tried to use preprocessors for 4.7 and above by following below link: http://smartfone-more.blogspot.in/2010/05/coding-for-multiple-blackberry-devices.html
now its working fine with JDE 4.7 but not getting expected result for 5.0. Please find the code below which i tried:
//#ifdef JDE_4_7_0
import net.rim.device.api.ui.component.ButtonField;
//#else
import net.rim.device.api.ui.component.LabelField;
//#endif
import net.rim.device.api.ui.container.MainScreen;
public class TestScreen extends MainScreen{
TestScreen(){
//#ifdef JDE_4_7_0
ButtonField btn = new ButtonField("Test Button");
add(btn);
//#else
LabelField lbl1 = new LabelField("Test Label 1");
add(lbl1);
//#endif
}
}
As per the code i am expecting the result written in else part for 5.0 and if part for 4.7. I checked it on device as well as JDE both.
Please Help.