Why not get an OBDC connection between excel and your DB and import it directly instead of sending it to text first ?
In other words use the excel sheet as your front end.
Hi All,
Can anyone solve this problem.
I have an automated program that generates 5 text files every day from oracle.
Now i want an automation for those 5 five files to be picked up and transferred into excel spread sheets without my interaction.
In that i have some columns to be made some formatting. And while saving the files it should append the date stamp to the filename.
Is this possible ? If so can any one help me?
If so i will be glad to give more info.
Any help would be appreciated.
Why not get an OBDC connection between excel and your DB and import it directly instead of sending it to text first ?
In other words use the excel sheet as your front end.
Can you tell me how to do that way, as it should run daily without my intervention.
the filenames should be datestamped everyday.
And how to get an odbc connection, can you help me. thanks in advance.
No body knows how?
I hope no GURUs out there. Not even whether it is possible or not answer coming to me.
You have made four posts in a little over 1 hour!!! And you have nearly dismissed the one answer already provided.
Please show some patience.
You might also be able to achieve your ends by running a macro at a set time and do something like the following (untested):
'-------------
Sub test()
Dim strFileName
Workbooks.OpenText FileName:="Extended Name of your file", Origin _
:=xlWindows, StartRow:=1, DataType:=xlDelimited, TextQualifier:= _
xlDoubleQuote, Tab:=True, FieldInfo:=Array(1, 2)
strFileName = Left(ActiveWorkbook.Name, _
Len(ActiveWorkbook.Name) - 4) & Format(Date, "mmddyyyy")
' do your stuff
With ActiveWorkbook
.SaveAs FileName:=strFileName, FileFormat:=xlNormal
.Close
End With
End Sub
'---------------------
You will do something like this for all your files.
HTH,
Jay
[ This Message was edited by: Jay Petrulis on 2002-05-09 16:13 ]
Thanks Jay.
But i dont know where to put this code and how to run it. can you please tell me step by step.
thanks in advance
Like this thread? Share it with others