Request here for libraries.

peacemaker

Expert
Licensed User
Longtime User
Maybe any help to have some "UpdateContact" function ? Updating NOTES without changing all other fields is needed...
 

peacemaker

Expert
Licensed User
Longtime User
Who and how much for can make B4A lib for this web-site SDK ?
Comments show that Eclipse should set up to use UTF8, as code uses some win1251 encoded texts.
 

michelg

Member
Licensed User
Longtime User
Hey everyone,



Now, Basic4Android still lack some functions that we, users, can implement with the form of a library.

Package Index | Android Developers

I won't wrap libraries. (Basically because I don't know on how to do it, or it is to hard :p)

Sincerely,
Tomas


Tomas,

Thank you for your willingness to help. Your kindness it greatly appreciated.

I have been refered to you by rbsoft.

Here is my scenario:
I have a VB6 Server, and I want it to be able to alert the user of an Android phone when specific events happen on the Server.

Alert could be:
ring the phone, email or anything that could make the user of the android phone contacts the server immediately.

All I need is how to alert the user:

VB6 on the server side and B4a on the Android side.

Please help! anything will be appreciated.

Thank you,
 

XverhelstX

Well-Known Member
Licensed User
Longtime User
Hey there,

This isn't the place to ask such questions.
You should start a new thread on the Basic4Android Updates & Questions.
However, i have some code lying around written in Vb.net;

B4X:
Imports System.Net
Imports System.Net.Sockets
Public Class Form1
    Dim sock As New TcpClient()
    Dim ip As IPAddress = IPAddress.Parse("127.0.0.1")
    Dim port As Integer = 10130
    Private Sub connect()
        If TextBox_IP.Text = "localhost" Then
            TextBox_IP.Text = "127.0.0.1"
        End If
        ip = IPAddress.Parse(TextBox_IP.Text)
        port = TextBox_Port.Text
        Try
            sock.Connect(ip, port)
            lblState.Text = "Connected!"
            Btn_Connect.Text = "Disconnect!"

        Catch ex As Exception
            MsgBox("Unable to connect to server. Other device might be offline.")
            lblState.Text = "Disconnected!"
            Btn_Connect.Text = "Connect!"
        End Try
    End Sub

    Private Sub dat(ByVal dat As String)
        Dim nstream As NetworkStream = sock.GetStream()
        Dim bit As [Byte]() = System.Text.Encoding.ASCII.GetBytes(dat)
        nstream.Write(bit, 0, bit.Length)
    End Sub


    Private Sub Btn_Connect_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btn_Connect.Click
        connect()
    End Sub

    Private Sub Btn_Path_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
        dat("0*" + TextBox_Path.Text)
    End Sub

    Private Sub Btn_Send_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
        dat("1*" + TextBox_Send.Text)
    End Sub

    Private Sub Btn_OpenCD_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
        dat("2*")
    End Sub


    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

    End Sub

End Class

That's the server on vb.net however it doesn't work asynchrounosly.
However this server will connect to your device.

In Basic4Android you could also use TCP/IP sockets to connect to the device.
There are enough examples here on the forum.
Some things you'd need to know:
- Only works on LAN
- connect to internal IP

You should take a look at sockets, asyncstreams.
If you could send data from your server to you client (android), you are able to use async streams to receive the data and decode it.
Next you can execute commands from the data with a select case. (You could convert the bytes to text)

Kind regards,
Tomas
 

Roger Garstang

Well-Known Member
Licensed User
Longtime User
A library to get Font Metric type info would be awesome. Something that can tell the max height/width of a character in a given Font. Something simple like passing it a Typeface and a size and it coming back with a Rect big enough to contain any char of that font. I've had a few threads lately concerning measuring font sizes and my View Manager Class if you need ideas. Being able to get length and width of a text string without a canvas or view added to a panel/activity being required would be cool too.

Being able to get a Typeface for built-in controls without a Typeface would go along with this class as well to provide a Typeface to work with for controls like a Spinner (android.R.layout.simple_spinner_item).
 
Last edited:

microbox

Active Member
Licensed User
Longtime User
Hi, I'm trying to find a library for the basic functionality of simpleCv(image capturing, writing text and color/pixel detection).

Thanks in advance
 

aaronk

Well-Known Member
Licensed User
Longtime User
How about a SSL Socket Library?

At the minute there is a network library that allows normal socket connections to send data to a IP/Port but I need the same type of thing that allows SSL Sockets.
 
Top