Solved

Delete Access2k table from VB

Posted on 2002-07-17
8
138 Views
Last Modified: 2010-05-02
a code snippet any1 :o)
0
Comment
Question by:djdidge
  • 3
  • 3
  • 2
8 Comments
 

Expert Comment

by:Amitabh
Comment Utility

strsql = "delete from NCT_mast"
prs.Open strsql, conn

hope this is what u want
0
 

Expert Comment

by:Amitabh
Comment Utility
here NCT_Mast is the table u want to delete and conn is the connection with ur access2K mdb.
0
 
LVL 14

Accepted Solution

by:
ajexpert earned 75 total points
Comment Utility
if you want to drop table then following snippet may help


cn.execute " DROP table <your tablename>"
0
 
LVL 2

Author Comment

by:djdidge
Comment Utility
thanks for your reply...but it doesnt seem to do anything
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 2

Author Comment

by:djdidge
Comment Utility
is DROP the term used to remove a table from the DB? (not the records)
0
 

Expert Comment

by:Amitabh
Comment Utility
yes if u want to remove the table use drop as aj said.
0
 
LVL 14

Expert Comment

by:ajexpert
Comment Utility
does it gave any error.  if so, what is the error message
0
 
LVL 2

Author Comment

by:djdidge
Comment Utility
Thanks both for responding quickly!

ajexpert you get the points coz "DROP table" worked for me


Cheers
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now