Bonjour,
je rame sur un export de requête en fichier txt...
Réponse : la spécification de fichier texte "," n'existe pas
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9 nomrepart = [Forms]![MENU]![Modifiable2] mois = Format(Month(Now()), "00") an = Right(Format(Year(Now()), "00"), 2) jour = Replace(Str(Date), "/", "-") delim = "," Nomfichier = ("P:\REPARTYR\Exportation\REP") & mois & an & ("_") & nomrepart & ("_") & jour & Time & (".txt") DoCmd.TransferText acExportDelim, ",", "R-EXPrepartBE", Nomfichier, False, ""
Et si je l'écris comme ça
Réponse : Le séparateur de spécification du fichier texte est identique au séparateur décimal ou au délimiteur de texte.
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9 nomrepart = [Forms]![MENU]![Modifiable2] mois = Format(Month(Now()), "00") an = Right(Format(Year(Now()), "00"), 2) jour = Replace(Str(Date), "/", "-") delim = "," Nomfichier = ("P:\REPARTYR\Exportation\REP") & mois & an & ("_") & nomrepart & ("_") & jour & Time & (".txt) DoCmd.TransferText acExportDelim, , "R-EXPrepartBE", Nomfichier, False, ""
Pour info mon fichier text doit être séparé par des virgules.
Merci d'avance
Partager