Search notes:

VBA Module CommonFunctionalityApp [Access]

sub appTitle(text as string) ' {

  call appProperty("AppTitle", dbText, text)
  application.refreshTitleBar

end sub ' }

function appProperty(strName As String, varType As Variant, varValue As Variant) As Integer ' {
' https://msdn.microsoft.com/en-us/library/bb256834(v=office.12).aspx
'
' TODO should this function be moved to its own «CommonFunctionalityApp.bas»?
'
  dim db As Object, prp As Variant
  const conPropNotFoundError = 3270

  set db = CurrentDb
  on error goto nok
  db.Properties(strName) = varValue
  appProperty = true

ok:
    exit function

nok:
  if err = conPropNotFoundError Then
     set prp = db.CreateProperty(strName, varType, varValue)
     db.Properties.Append prp
     resume
  else
     appProperty = false
     resume ok
  end if

end function ' }
Github repository VBAModules, path: /Access/CommonFunctionalityApp.bas

See also

René's VBA Modules

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1759414190, '216.73.216.42', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/languages/VBA/modules/Access/CommonFunctionalityApp(71): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78