|
-
Mar 8th, 2007, 05:49 AM
#1
Thread Starter
Junior Member
Edit/Update csv file
hi. I'm new here.
just want to ask if there's away to edit/update a csv file record.
I'm using ODBC Text File Driver. I've read it only supports Insert.
Are there other ways to do this?
thanks in advance.
-
Mar 8th, 2007, 07:06 AM
#2
-
Mar 8th, 2007, 12:08 PM
#3
Re: Edit/Update csv file
Why not just use the basic File I/O?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Mar 8th, 2007, 12:19 PM
#4
Re: Edit/Update csv file
You should be able to update... what's not allowed is delete. What error messages are you getting and whats your code?
-
Mar 8th, 2007, 07:43 PM
#5
Thread Starter
Junior Member
Re: Edit/Update csv file
Hi. thanks for the reply.
this is the error that I'm getting when I try to update:
Connectivity error: [Microsoft][ODBC Text Driver] Updating data in an attached (or linked) table not supported by this ISAM.
this is my update code:
If RS_TimeOut.RecordCount > 0 Then
RS_TimeOut.MoveFirst
RS_TimeOut!out_hh = IntOutH
RS_TimeOut!out_mi = strTMi
RS_TimeOut!kintai_status = Val(tmpKintaiStatus) + Val(updKinStat)
RS_TimeOut!out_db_dh = Date & " " & Time
RS_TimeOut!upd_dh = Date & " " & Time
RS_TimeOut!edit_flg = "1"
RS_TimeOut.Update
End If
thanks in advance!
-
Mar 8th, 2007, 08:49 PM
#6
Re: Edit/Update csv file
What's your connection string?
-
Mar 8th, 2007, 09:19 PM
#7
Thread Starter
Junior Member
Re: Edit/Update csv file
hi. this is my connection string.
Driver={Microsoft Text Driver (*.txt; *.csv)};};Dbq=c:\Program Files\Microsoft Visual Studio\VB98\syain_login1\Data\;Extensions=asc,csv,tab,txt;
hope you can help me out.
thanks.
-
Mar 9th, 2007, 07:49 AM
#8
Re: Edit/Update csv file
I stand corrected, it seems update isn't possible on a linked text file.
If you don't want to perform file I/O as suggested earlier, you can use excel automation and work with the csv as a worksheet. There may be other alternatives, we'll have to wait for others to give their own suggestions.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|