10 messages in org.openoffice.fr.progRe: [prog] OOo 1.1.5 - Connection - d...
FromSent OnAttachments
Ludovic CHEVALIERMar 16, 2006 8:37 am 
christian bienassisMar 16, 2006 9:12 am 
Bernard MarcellyMar 16, 2006 12:06 pm 
oo...@volcar.orgMar 16, 2006 11:03 pm 
Laurent GodardMar 17, 2006 12:18 am 
Laurent GodardMar 17, 2006 12:30 am 
chri...@free.frMar 17, 2006 1:13 am 
Ludovic CHEVALIERMar 17, 2006 1:45 am 
Bernard MarcellyMar 17, 2006 1:56 am 
Ludovic CHEVALIERMar 17, 2006 2:20 am 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: [prog] OOo 1.1.5 - Connection - déconnection sourceActions...
From:Ludovic CHEVALIER (tens@no-log.org)
Date:Mar 17, 2006 1:45:39 am
List:org.openoffice.fr.prog

Salut!

Merci Bernard.

Voici ma nouvelle fonction de connexion qui fonctionne a merveille (rapidité, efficacité).

A bientôt,

Ludo

'Se connecte à une source de données Function ConnecterSource(NomSource as String) as Object Dim maSource As Object, monDbContext As Object, demandePasse as Object 'Création du contexte monDbContext = CreateUnoService( _ "com.sun.star.sdb.DatabaseContext") maSource=monDbContext.getByName(NomSource)

'Les paramètres de connexion demandePasse = CreateUnoService("com.sun.star.sdb.InteractionHandler") ConnecterSource = maSource.getIsolatedConnectionWithCompletion(demandePasse) ConnecterSource.autoCommit = false

if IsNull(ConnecterSource) then MsgBox("Connexion impossible",16) End if End Function