PostgreSQLDatabase.SSL

From Xojo Documentation

Property (As Boolean )
aPostgreSQLDatabase.SSL = newBooleanValue
or
BooleanValue = aPostgreSQLDatabase.SSL

Supported for all project types and targets.

Specifies whether to connect to PostgreSQL using SSL. The default is False.

Examples

This example connects to an existing PostgreSQL database using SSL.

Var db As New PostgreSQLDatabase
db.Host = "192.168.1.172"
db.SSL = True
db.DatabaseName = "myDatabase"
db.Username = "Charlie"
db.Password = "mashie"
Try
db.Connect
//proceed with database operations
Catch error As DatabaseException
MessageBox("The connection failed.Error: " + error.Message)
End Try