IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

InfoPath .NET Discussion :

Object VBscript pour créer et traiter des fichiers XML.


Sujet :

InfoPath .NET

  1. #1
    Membre à l'essai
    Inscrit en
    Janvier 2008
    Messages
    19
    Détails du profil
    Informations forums :
    Inscription : Janvier 2008
    Messages : 19
    Points : 16
    Points
    16
    Par défaut Object VBscript pour créer et traiter des fichiers XML.
    Hello,

    Habituellement, on utilise l'objet "Microsoft.XMLDOM" pour gérer les fichier XML en VBS.
    Avec Infopath, il semble que cela pose quelques porblèmes.

    Est-ce que quelqu'un connait une alternative ?
    Sinon quelqu'un connait - il un truc pour récupérer des données d'un formulaire ouvert et les mettre dans un fichier XML spécial ?

    Merci

  2. #2
    Membre expérimenté
    Avatar de virgul
    Profil pro
    Inscrit en
    Novembre 2004
    Messages
    1 625
    Détails du profil
    Informations personnelles :
    Âge : 39
    Localisation : Suisse

    Informations forums :
    Inscription : Novembre 2004
    Messages : 1 625
    Points : 1 666
    Points
    1 666
    Par défaut
    Salut,

    Oui effectivement il faut utiliser XDocument.

    Télécharge le SDK d'infopath (celui de la version 2003) et va voir dans le Infopath SDK documentation.
    "Life is short don't forget to inhale"
    Mais: "Mieux vaux arriver en retard dans ce monde... qu'en avance à l'autre."

  3. #3
    Futur Membre du Club
    Homme Profil pro
    Administrateur systèmes et réseaux
    Inscrit en
    Août 2013
    Messages
    4
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Activité : Administrateur systèmes et réseaux
    Secteur : High Tech - Opérateur de télécommunications

    Informations forums :
    Inscription : Août 2013
    Messages : 4
    Points : 5
    Points
    5
    Par défaut InfoPath DSK 2003 : XDocuments
    Bonjour,
    Voci un extrait du fichier : ipsdk.chm, ci-dessous.
    Je vois des ; à la fin des lignes de codes.
    Est-ce vraiment du VBS ?
    Cdlt,



    ----
    XDocuments Collection
    See AlsoPropertiesMethodsEventsSpecificsXDocuments
    XDocument


    Contains an XDocument object for each Microsoft Office InfoPath 2003 form that is currently open. The XDocument object represents a form's underlying XML document and can be used to interact with the XML data that a form contains.

    Remarks
    The XDocuments collection implements a number of properties and methods that can be used to access a form's associated XDocument object, or to create and open the forms themselves. The XDocuments collection is accessed through the XDocuments property of the Application object.

    Using the XDocuments collection
    In the following example, the Open method of the XDocuments collection is used to open an existing form:

    Application.XDocuments.Open("C:\\MyForm.xml");
    You can also create a new form based on an existing form using the New method:

    Application.XDocuments.New("C:\\MyForm.xml");
    To access an XDocument object contained in the XDocuments collection, you can pass the positional index or the location path to the Item method:

    var objXDoc;

    objXDoc = Application.XDocuments(0);
    // or...
    objXDoc = Application.XDocuments("C:\\MyForm.xml");
    For more information about using the XDocuments collection, see Accessing form data.

    ---

  4. #4
    Futur Membre du Club
    Homme Profil pro
    Administrateur systèmes et réseaux
    Inscrit en
    Août 2013
    Messages
    4
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Activité : Administrateur systèmes et réseaux
    Secteur : High Tech - Opérateur de télécommunications

    Informations forums :
    Inscription : Août 2013
    Messages : 4
    Points : 5
    Points
    5
    Par défaut MS InfoPath 2003 SDK : XDocuments vs VBS
    Citation Envoyé par kercyr Voir le message
    Bonjour,
    Voci un extrait du fichier : ipsdk.chm, ci-dessous.
    Je vois des ; à la fin des lignes de codes.
    Est-ce vraiment du VBS ?
    Cdlt,



    ----
    XDocuments Collection
    See AlsoPropertiesMethodsEventsSpecificsXDocuments
    XDocument


    Contains an XDocument object for each Microsoft Office InfoPath 2003 form that is currently open. The XDocument object represents a form's underlying XML document and can be used to interact with the XML data that a form contains.

    Remarks
    The XDocuments collection implements a number of properties and methods that can be used to access a form's associated XDocument object, or to create and open the forms themselves. The XDocuments collection is accessed through the XDocuments property of the Application object.

    Using the XDocuments collection
    In the following example, the Open method of the XDocuments collection is used to open an existing form:

    Application.XDocuments.Open("C:\\MyForm.xml");
    You can also create a new form based on an existing form using the New method:

    Application.XDocuments.New("C:\\MyForm.xml");
    To access an XDocument object contained in the XDocuments collection, you can pass the positional index or the location path to the Item method:

    var objXDoc;

    objXDoc = Application.XDocuments(0);
    // or...
    objXDoc = Application.XDocuments("C:\\MyForm.xml");
    For more information about using the XDocuments collection, see Accessing form data.

    ---

  5. #5
    Membre éprouvé
    Homme Profil pro
    Référent technique
    Inscrit en
    Juillet 2007
    Messages
    834
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 40
    Localisation : France, Pyrénées Atlantiques (Aquitaine)

    Informations professionnelles :
    Activité : Référent technique

    Informations forums :
    Inscription : Juillet 2007
    Messages : 834
    Points : 1 219
    Points
    1 219
    Par défaut
    L'exemple suivant vous expliquera comment manipuler le VBScript dans InfoPath :
    http://blogs.msdn.com/b/davfries/arc...24/195300.aspx

    Cordialement.
    Rémi MATAYRON
    N'hésitez pas à visiter mon blog dédié à InfoPath et SharePoint : http://rmatayron.blogspot.com/

    Pour plus de visibilité sur le forum, marquer la question en [Résolu] lorsque la réponse fournie vous convient.

Discussions similaires

  1. conseils de modules pour traiter des fichiers XML
    Par Jasmine80 dans le forum Langage
    Réponses: 4
    Dernier message: 29/05/2015, 12h40
  2. [AC-2002] Boucle pour importer et traiter des fichiers excel dans un dossier
    Par Tinien dans le forum VBA Access
    Réponses: 9
    Dernier message: 02/06/2010, 11h59
  3. [DTD] utiliser avec JAVA des fichiers DTD pour vérifier la validité des fichiers XML
    Par Balbuzard dans le forum Format d'échange (XML, JSON...)
    Réponses: 1
    Dernier message: 20/04/2009, 12h10
  4. Réponses: 9
    Dernier message: 05/04/2005, 09h39
  5. [Tomcat][Servlet] créer et acceder à des fichier du localhos
    Par djodjo dans le forum Tomcat et TomEE
    Réponses: 2
    Dernier message: 12/01/2004, 17h30

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo