473,386 Members | 2,042 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Help Required In Uploading Excel Files Into Access

hi,
i am creating a form with a text field and two command buttons in vb 6.0
I want when somebody will click on command1 button a path will be shown in the text field.

And for second command button i want when somebody clicks in it, Data will be updated in an access file as we receive excel files on daily basis.

for command1 i did following but gettting an error of object required and it gets highlighted on Set fd = Application.FileDialog(msoFileDialogFilePicker)

Private Sub Command1_Click()
Const conVerticalOnly As Integer = 2
'Declare a variable as a FileDialog object.
Dim fd As FileDialog, strFilesSelected As String
Set fd = Application.FileDialog(msoFileDialogFilePicker)
'Declare a variable to contain the path, it must be a Variant because

'of the For..Each construct requires it

Dim vrtSelectedItem As Variant
With fd
.AllowMultiSelect = True

.Title = "Browse Files"
If .Show = -1 Then

For Each vrtSelectedItem In .SelectedItems

strFilesSelected = strFilesSelected & vrtSelectedItem & vbCrLf

Next vrtSelectedItem

Else

'The user pressed Cancel

End If

End With

Set fd = Nothing

Me![txtDisplayFileNames ].ScrollBars = conVerticalOnly
Me![txtDisplayFileNames] = strFilesSelect
End Sub


for command button2 i am not geting any idea how to go ahead.
KIndly help me.
i have also added Microsoft office 11.0 object library.
Oct 10 '07 #1
1 1321
hi,

Has anybody is having any idea.....how should i go ahead.

Plz revert its very urgent requirement for me.

thanx
Anup
Oct 10 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: dickiedyce | last post by:
Hi there. I've spent the weekend getting ever more frustrated, trying to get an upload file function working on a website. The site is hosted by a company called oneandone. They're using PHP...
0
by: gunimpi | last post by:
http://www.vbforums.com/showthread.php?p=2745431#post2745431 ******************************************************** VB6 OR VBA & Webbrowser DOM Tiny $50 Mini Project Programmer help wanted...
3
by: alnug | last post by:
Hello, I'm trying to use the following code to read data from Excel files and put the data into an MS Access Table. Some of the Excel files have the tabs in the sequence Chart1, Sheet1, Sheet2 etc...
3
by: smugcool | last post by:
hi, i am creating a form with a text field and two command buttons. I want when somebody will click on command1 button a path will be shown in the text field. And for second command button i...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.