« CreateDocument (TdbfDocument) » : différence entre les versions

De Wiki1000
m (Remplacement du texte — « category:Latest » par « Category:Version700 »)
Aucun résumé des modifications
 
Ligne 1 : Ligne 1 :
<source lang='delphi'>class function CreateDocument(const iName,iOidObject,iDataURL:string);</source>
<source lang='delphi'>class function CreateDocument(const iName,iOidObject,iDataURL:string):TdbfDocument;</source>


Cette fonction crée un document et le rattache à un objet.
Cette fonction crée un document et le rattache à un objet.

Dernière version du 18 avril 2017 à 13:18

<source lang='delphi'>class function CreateDocument(const iName,iOidObject,iDataURL:string):TdbfDocument;</source>

Cette fonction crée un document et le rattache à un objet.

iName Nom du document créé
iOidObject Identifiant de l'objet auquel rattaché le document
iDataURL Contenu du document au format todataURL()


Exemple : <source lang='delphi'> begin

withP transaction do
 begin
   ndf := TNoteFrais.Create;
   ndf.nDate := Now;
   ndf.referencePiece := req.ref;
   ...
   if req.Exists('photo') and (req.photo<>) then
    begin
      TdbfDocument.CreateDocument('ndf-',ndf.InstanceOID,req.photo);
    end;
 end;

end; </source>

Voir aussi:

{{#if:TdbfDocument|

{{#if:TdbfDocument|— TdbfDocument |}} — Développement DSM

|

{{#if:|— [[{{{1}}}]] |}} — Développement DSM

}}