?
Solved

creating an addin to insert code into my vb project

Posted on 2004-08-06
4
Medium Priority
?
197 Views
Last Modified: 2012-05-05
Hello,

I want to create an add-in that, when called will insert 4 lines of text into the VB IDE . I don't know much about add-ins and would like to know if this is possible.  The text is placed where the curser is located .

Just wondering if anyone could give a few pointers as to how i'd get started  ?


Thanks.

Ken
0
Comment
Question by:kfc23
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 9

Accepted Solution

by:
dancebert earned 260 total points
ID: 11736930
Francesco Balena wrote an article in the Augues 97 Visual Basic Programmers Journal that describes in detail the object model needed to write an add-in that communicates with the IDE.  I just skimmed the article, it doesn't explictly say one can insert code, but it doesn't say one can't either.  VBPJ archives are at www.devx.com.  I don't have a URL for the article, just a xerox copy of the dead tree version.  Title of the article is 'Roll your own Add-ins'
0
 
LVL 7

Assisted Solution

by:Burbble
Burbble earned 240 total points
ID: 11737922
Here's a good example:
http://www.frez.co.uk/vbaddindemo.zip

There is a "Timestamp" function that I believe inserts lines into the code window. You can modify it to do whatever you want.

-Burbble
0
 
LVL 7

Expert Comment

by:Burbble
ID: 11752351
It looks like you got it working, glad I could help ;-)

-Burbble
0
 

Author Comment

by:kfc23
ID: 11752932
ya both comments were very helpful . works great. thanks a lot.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
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…
Suggested Courses
Course of the Month9 days, 17 hours left to enroll

762 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