is it possible to create a lib
where i define some constants to be used in different apps
exactly like the "colors" constants?
i have written the lib
but i have to declare a variable to use it
i'd like instead to use it in this way
tia
where i define some constants to be used in different apps
exactly like the "colors" constants?
i have written the lib
B4X:
import anywheresoftware.b4a.BA.DontInheritEvents;
import anywheresoftware.b4a.BA.ShortName;
@DontInheritEvents
@ShortName("eFieldKind")
public final class eFieldKind
{ public static final int SEASON_WINTER = 0;
public static final int SEASON_SPRING = 1;
public static final int SEASON_SUMMER = 2;
public static final int SEASON_FALL = 3;
}
B4X:
DIM fk AS eFieldKind
...
IF S = fk.SEASON_WINTER THEN
...
END IF
i'd like instead to use it in this way
B4X:
...
IF S = eFieldKind.SEASON_WINTER THEN
...
END IF
Last edited: