Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
2976 connectés 

  FORUM HardWare.fr
  Programmation
  SQL/NoSQL

  Inventaire : importation d'info d'un fichier txt vers ms access 2000

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

Inventaire : importation d'info d'un fichier txt vers ms access 2000

n°995722
jijun
Posté le 28-02-2005 à 13:52:15  profilanswer
 

Salut à tous!  
 
Je voulais savoir s'il est possible, d'importer les données à partir d'un fichier texte, et de les réinjecter dans une base access?  
 
le fichier texte se présente ainsi :  
 
 
Kernel version:            Microsoft Windows 2000, Uniprocessor Free  
Product type:              Professional  
Product version:           5.0  
Service pack:              4  
Kernel build number:       2195  
Registered organization:   DJ_SNIPER_007  
Registered owner:          JKA  
Install date:              03/01/2004, 19:41:34  
Activation status:         Not applicable  
IE version:                6.0000  
System root:               C:\WINNT  
Processors:                1  
Processor speed:           865 MHz  
Processor type:            Intel Pentium III  
Physical memory:           896 MB  
Video driver:              NVIDIA Quadro2 Pro  
Volume Type       Format     Label                      Size       Free   Free  
    A: Removable                                                            0%  
    C: Fixed      NTFS       System                  23.4 GB    17.1 GB    73%  
    D: CD-ROM     CDFS       Norton&Diskeeper       519.4 MB                0%  
 
Applications:  
ASUS TV FM CARD 2.3.4.1  
ASUS TV FM CARD 2.3.4.1  
Adobe Reader 6.0.1 - Franþais 006.000.001  
Correctif LecteuráWindows Mediaá9 [Voir KB885492 pour plus d'informations]  
Correctif Windows 2000 (SP5) KB820888 20030604.152521  
Correctif Windows 2000 (SP5) Q818043 20030501.174006  
Correctif Windows 2000 - KB329115 20031024.155236  
Correctif Windows 2000 - KB822831 20030611.114034  
Correctif Windows 2000 - KB823182 20030618.121409  
Correctif Windows 2000 - KB823559 20030627.135515  
Correctif Windows 2000 - KB824105 20030716.151320  
Correctif Windows 2000 - KB825119 20030827.151123  
Correctif Windows 2000 - KB826232 20031007.160553  
Correctif Windows 2000 - KB828035 20031023.142138  
Correctif Windows 2000 - KB828741 20040311.130332  
Correctif Windows 2000 - KB828749 20031023.124056  
Correctif Windows 2000 - KB833407 20040119.115651  
Correctif Windows 2000 - KB835732 20040323.171849  
Correctif Windows 2000 - KB837001  
Correctif Windows 2000 - KB839643 20040506.120130  
Correctif Windows 2000 - KB839645 20040519.160457  
Correctif Windows 2000 - KB840315 20040622.153749  
Correctif Windows 2000 - KB840987 20040825.01015  
Correctif Windows 2000 - KB841356 20040730.185536  
Correctif Windows 2000 - KB841533 20040824.233811  
Correctif Windows 2000 - KB841872 20040520.90850  
Correctif Windows 2000 - KB841873 20040610.95344  
Correctif Windows 2000 - KB842526 20040521.202909  
Correctif Windows 2000 - KB867282 20050127.163319  
Correctif Windows 2000 - KB871250 20041104.203738  
Correctif Windows 2000 - KB873333 20050113.171731  
Correctif Windows 2000 - KB873339 20041116.24305  
Correctif Windows 2000 - KB885250 20050119.234138  
Correctif Windows 2000 - KB885835 20041101.10457  
Correctif Windows 2000 - KB885836  
Correctif Windows 2000 - KB888113 20041116.23251  
Correctif Windows 2000 - KB889293 20041111.235619  
Correctif Windows 2000 - KB890047 20041210.11626  
Correctif Windows 2000 - KB890175 20041122.80359  
Correctif Windows 2000 - KB891711 20041229.10717  
Correctif Windows 2000 - KB891781 20050113.171736  
Correctif pour DirectX 8.1 - KB839643  
Correctif pour le Lecteur Windows Media [Voir Q828026 pour plus d'informations]  
InterVideo Home Theater  
J2SE Runtime Environment 5.0 Update 1 1.5.0.10  
LiveUpdate 2.0 (Symantec Corporation) 2.0.39.0  
MSN Messenger 6.2 6.2.0205  
Microsoft .NET Framework 1.1 1.1.4322  
Microsoft .NET Framework 1.1  
Microsoft .NET Framework 1.1 Hotfix (KB886903)  
Microsoft Baseline Security Analyzer 1.2.1 1.2.4013.0  
Microsoft Data Access Components KB870669  
Microsoft Internet Explorer 6 SP1  
Microsoft Office Professional Edition 2003 11.0.6361.0  
Microsoft VGX Q833989  
Mise Ó jour systÞme du Lecteur Windows Media (SÚrie 9)  
Mozilla Firefox (1.0) 1.0 (fr-FR)  
NVIDIA Drivers  
Nero OEM  
Symantec AntiVirus 9.0.0.338  
hp deskjet 970c series (Supprimer uniquement)  
 
Donc je voudrais que chaque info rentre dans son champs respectif dans la base access.  
 
Si qqn à une idée?

mood
Publicité
Posté le 28-02-2005 à 13:52:15  profilanswer
 

n°995907
jijun
Posté le 28-02-2005 à 15:37:12  profilanswer
 

up

n°996962
jijun
Posté le 01-03-2005 à 11:46:20  profilanswer
 

up

n°996981
vttman2
Je suis Open ...
Posté le 01-03-2005 à 12:08:57  profilanswer
 

OUI
Par exemple ...
Un import dans une table Access temporaire
puis un balayage (open recordset) de chaque ligne  
et à chaque fois un décodage de la ligne / recherche de mot clef et valeur, suivi d'un insert en base Runsql...

n°996988
jijun
Posté le 01-03-2005 à 12:20:44  profilanswer
 

Merci pour ta réponse.
Chuis newbie en programmation.
Pourrais-tu détailler un peu plus stp?
Si t'as un lien à proposer?
Merci bcp

n°997048
vttman2
Je suis Open ...
Posté le 01-03-2005 à 13:35:38  profilanswer
 

* Tu peux regarder l'aide sous Access sur TransferText pour la partie Import
* Ex de parcours d'enregistrements avec un recordset
=>
Private Sub connexion_Click()
Me.Requery
Dim sql As String
Dim rs As DAO.Recordset
sql = "SELECT * FROM TableTemp"  
Set rs = CurrentDb.OpenRecordset(sql)
rst.MoveFirst
While Not rst.Eof
    ' Traitement de chaque ligne docmd.Runsql "Insert ou  
    ' Update...
    rst.MoveNext
Wend
rst.Close
Endsub
 
Sinon niveau lien tu peux regarder ici
=> http://access.developpez.com/faq/
 


Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  SQL/NoSQL

  Inventaire : importation d'info d'un fichier txt vers ms access 2000

 

Sujets relatifs
conversion HTML vers PDFtaritement chaîne de caractères sous access
transfert de fichier par tubefaire un lien de .swf vers une page html
Vérouillage lecture fichier[Résolu] VS7-syntaxe highlighting avec n'importe quelle ext° fichier
[PHP] Créer des fichier de police pour PHPCommandes FTP - Copier un fichier ??
evenement sur liste deroulante dans accessrecherche forum asp avec bd access
Plus de sujets relatifs à : Inventaire : importation d'info d'un fichier txt vers ms access 2000


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR