Robert Valentino Well-Known Member Licensed User Longtime User Mar 29, 2014 #1 I am nearing the end of a project I have been working on and now have the task of how to handle multiple versions a Trial / Free version and a paying version. It sure would be nice if the B4A development IDE allowed us to have #ifdef so we could define a global variable to the compiler and then use it to test what code to compile. #ifdef _TRAIL_OR_TEST_VERSION <-- Would be defined somewhere in the IDE interface ... compile this code #else ... compile this code #endif I do this in Visual Studio all the time #ifdef _DEBUG .. If compiling in Debug Mode include this code #endif I think this is something that Erel could add pretty easily - I noticed the compiler when generating the java code dumps all the comments I put in my code, so why can we not dump or include all the code in a #ifdef Just a thought to make supporting multiple version easier. BobVal
I am nearing the end of a project I have been working on and now have the task of how to handle multiple versions a Trial / Free version and a paying version. It sure would be nice if the B4A development IDE allowed us to have #ifdef so we could define a global variable to the compiler and then use it to test what code to compile. #ifdef _TRAIL_OR_TEST_VERSION <-- Would be defined somewhere in the IDE interface ... compile this code #else ... compile this code #endif I do this in Visual Studio all the time #ifdef _DEBUG .. If compiling in Debug Mode include this code #endif I think this is something that Erel could add pretty easily - I noticed the compiler when generating the java code dumps all the comments I put in my code, so why can we not dump or include all the code in a #ifdef Just a thought to make supporting multiple version easier. BobVal
DonManfred Expert Licensed User Longtime User Mar 29, 2014 #2 There is no such function in B4A but you can use this Tool from @MaFu .
Robert Valentino Well-Known Member Licensed User Longtime User Mar 29, 2014 #3 Yes I understand B4A does not support this, that is why I put it on the Wish List. Your tool looks very interesting but I believe we need something directly supported by B4A Thanks
Yes I understand B4A does not support this, that is why I put it on the Wish List. Your tool looks very interesting but I believe we need something directly supported by B4A Thanks
DonManfred Expert Licensed User Longtime User Mar 29, 2014 #4 Robert Valentino said: Yes I understand B4A does not support this, that is why I put it on the Wish List. Your tool looks very interesting but I believe we need something directly supported by B4A Click to expand... It´s not my tool. I understand that you want this feature in b4a directly built-in. I´m with you
Robert Valentino said: Yes I understand B4A does not support this, that is why I put it on the Wish List. Your tool looks very interesting but I believe we need something directly supported by B4A Click to expand... It´s not my tool. I understand that you want this feature in b4a directly built-in. I´m with you
MaFu Well-Known Member Licensed User Longtime User Apr 2, 2014 #5 I have updated B4Aconditioner, it's now compatible with Basic4Android 3.x.
Robert Valentino Well-Known Member Licensed User Longtime User Apr 3, 2014 #6 Thanks, I will look into using this. I just wish this was built into the B4A IDE.
D daemon Active Member Licensed User Longtime User Dec 5, 2014 #7 @Erel Bumping it up for v4.00 In 3.82, #If and #End If are supported but #Else or #Else If are not. Please support them in v4.
@Erel Bumping it up for v4.00 In 3.82, #If and #End If are supported but #Else or #Else If are not. Please support them in v4.
derez Expert Licensed User Longtime User Dec 5, 2014 #8 Reminding that the "build configurations" enable you to do it.
D daemon Active Member Licensed User Longtime User Dec 5, 2014 #9 Yes, but when you have multiple such macros, number of build configuration increases exponentially!