B4J Question I'm having a problem getting BCToast installed in B4J 8.50

Diceman

Active Member
Licensed User
I downloaded BCToast from BCToast Download and put BCToast.b4xlib into my B4X AdditionalLibraries folder: D:\Programming\B4X\B4X\AdditionalLibraries
Even though I downloaded it from the B4A forum, it is a B4X library so it should work in B4J, right?

When I load the sample app BCToast.B4J (from B4J-BCToast.zip ) I get errors on any reference to BCToast.
B4X:
Main - 30: Undeclared variable 'toast' is used before it was assigned any value.
Main - 20: Undeclared variable 'toast' is used before it was assigned any value.
Main - 19: Undeclared variable 'toast' is used before it was assigned any value.
Main - 18: Undeclared variable 'toast' is used before it was assigned any value.
Main - 10: Unknown type: bctoast<br />Are you missing a library reference?

I don't see a BCToast library in the Library Manager which means B4J can't see the library.

Maybe my directory structure is wrong?

D:\Programming\B4X\B4J\AdditionalLibraries
D:\Programming\B4X\B4J\Libraries
D:\Programming\B4X\B4J\SharedModules

D:\Programming\B4X\B4X\AdditionalLibraries
D:\Programming\B4X\B4X\B4X_AdditionalLibraries_XMLFiles

How does B4J know to find the BCToast.B4XLib in the folder D:\Programming\B4X\B4X\AdditionalLibraries?
I added "D:\Programming\B4X\B4X\AdditionalLibraries" to Additional Libraries path using the Paths Configuration dialog.
I even created the BCToast.XML file and put it into its folder "D:\Programming\B4X\B4X\B4X_AdditionalLibraries_XMLFiles".

No joy in Mudville. I struck out each time.
Can someone throw a ball over the plate so I can at least hit something today? ⚾

TIA
 

Attachments

  • PathsConfiguration.png
    PathsConfiguration.png
    10.1 KB · Views: 192

mcqueccu

Well-Known Member
Licensed User
Longtime User
You dont need to add two paths as additional libraries. Here is the folder structure

Create a folder called AdditionalLibraries (Set only this as the path in the configuration for all the platforms)

D:\Programming\B4X\AdditionalLibraries

The IDE will automatically select the folder it needs
1597807230325.png



NEXT inside the AdditionalLibraries folder, Create 5 folders like this
B4A (Put B4A specific libraries here)
B4J (Put B4J specific libraries here)
B4i (Put B4I specific libraries here)
B4X (For B4XLibs)
Shared ( D:\Programming\B4X\AdditionalLibraries\Shared )

1597807503670.png
 

Attachments

  • 1597807438662.png
    1597807438662.png
    196.9 KB · Views: 197
Upvote 0

Diceman

Active Member
Licensed User
Thanks for your detailed reply and the screen shots. It certainly helped.
What confused me was that I had to physically move my AdditionalLibraries folders out of their install directories like

D:\Programming\B4X\B4J\AdditionalLibraries
D:\Programming\B4X\B4A\AdditionalLibraries
D:\Programming\B4X\B4i\AdditionalLibraries

up to a higher directory level like

D:\Programming\B4X\AdditionalLibraries\B4J
D:\Programming\B4X\AdditionalLibraries\B4A
D:\Programming\B4X\AdditionalLibraries\B4i

I thought all of this could have been handled by adding an additional path to the "Additional Libraries" entry in the Paths Configuration dialog.
It didn't occur to me that I had to change my directory structure.

Thanks again for the help. I have it working. :D
 
Upvote 0
Top