Bug? Not sure if it's a bug with jRDC2 resumable Sub (b4J)

inakigarm

Well-Known Member
Licensed User
Longtime User
I've copied from the jRDC2 Post the following code:

B4X:
Sub InsertRecord (Name As String)
    Dim cmd As DBCommand = CreateCommand("insert_animal", Array(Name, Null))
    [CODE]Dim j As HttpJob = CreateRequest.ExecuteBatch(Array(cmd), Null)
    Wait For(j) JobDone(j As HttpJob)
    If j.Success Then
        Log("Inserted successfully!")
    End If
    j.Release
End Sub

The line
B4X:
Dim j As HttpJob = CreateRequest.ExecuteBatch(Array(cmd), Null)
displays an underline error (Warning 22: Types do not Match) and when trying to compile this error arises:
incompatible types: String cannot be converted to httpjob

Am I doing something wrong or this code is incorrect? I've B4J 5.90 and the last DBRequestManagerResumableSubs.zip

P.D: The intellisense displays that ExecuteBatch returns a String but in DBRequestManager it doesn't return a value
 

OliverA

Expert
Licensed User
Longtime User
You downloaded the wrong file. You need to download DBRequestManagerResumableSubs.zip and use the DBRequestManager.bas from it.
 

inakigarm

Well-Known Member
Licensed User
Longtime User
Found the issue:

On my B4J Folder I've 50 or so files (copies, backups, versions,etc) ; also I've a Folder for shareable Modules where I've downloaded the correct DBRequestManager.bas.

When adding the existing module from shareable folder in the IDE -> Project -> Add Existing Modules, the module continues to be the 'old' one; searching in the app folder I've found the 'old' DBRequestManager.bas; renaming and repeating the operation solved the problem (the new one is loaded)

Can be this to be considered as a bug ? (because even though choosing the right module (shareable folder), the loaded module is the one on the app folder)
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…