Zip some text files in access

J

Jason

Dear all,

I want to zip some text files in my access application by clicking button.
How can I do ?

Thanks.
Jason
 
T

Tony Toews [MVP]

J

Jason

Thank you very much for your help.

One more question, in the coding of your links, there are run time error at
following two coding :

1) FName = Application.GetOpenFilename(filefilter:="Excel Files (*.xls),
*.xls", _
MultiSelect:=True, Title:="Select
the files you want to zip")

2) Application.Wait (Now + TimeValue("0:00:01"))

Best regards,
Jason.
 
P

Peter Yang[MSFT]

Hello Jason,

Did you add the reference of Microsoft.Excel 12.0 object library? If not,
you could add in code window Tools->Add reference.

Please let's know if you have any further questions.

Best Regards,

Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support


=====================================================


======================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 
J

Jason

Hello Peter,

Thank you very much for your reply.
Could I add the reference by coding when startup my access application?
It is because the access application will give different user to use in
different PC.
If I can't do this, I may need to add the reference in each PC.

Best regards,
Jason.
 
P

Peter Yang[MSFT]

Hello Jason,

You don't need to add reference each time when you copy the database to
different machine. However, the component used in reference should be
installed on the machine you use it. Otherwise, you have to install the
component such as Office or Excel in your case.

You could see the link in following MVP's site for more related information
http://www.granite.ab.ca/access/addins.htm

If anything is unclear, please feel free to let's know. Thank you.

Best Regards,

Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support


=====================================================

When responding to posts, please "Reply to Group" via your
newsreader so that others may learn and benefit from this issue.
======================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 
T

Tony Toews [MVP]

Jason said:
Could I add the reference by coding when startup my access application?
It is because the access application will give different user to use in
different PC.
If I can't do this, I may need to add the reference in each PC.

Late binding means you can safely remove the reference and only have
an error when the app executes lines of code in question. Rather than
erroring out while starting up the app and not allowing the users in
the app at all. Or when hitting a mid, left or trim function call.

This also is very useful when you don't know version of the external
application will reside on the target system. Or if your organization
is in the middle of moving from one version to another.

For more information including additional text and some detailed links
see the "Late Binding in Microsoft Access" page at
http://www.granite.ab.ca/access/latebinding.htm

Tony
--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
Tony's Microsoft Access Blog - http://msmvps.com/blogs/access/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top