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
Solved

VB.net Excel Add-in 'xlEdgeTop' is not declared.

Posted on 2014-03-12
2
665 Views
Last Modified: 2014-03-12
Hi

In my VB.net Excel Add-in I am trying to work with cell borders. In the code below I get the error 'xlEdgeTop' is not declared. How do I correct this?

   C = Globals.ThisAddIn.Application.Selection.Borders(xlEdgeTop).ColorIndex
0
Comment
Question by:murbro
2 Comments
 
LVL 33

Accepted Solution

by:
Norie earned 500 total points
ID: 39924617
Looks like xlEdgeTop is being treated as an undeclared variable in your add-in.

Try fully qualifying it, something like this perhaps.
xlApp.XlBordersIndex.xlEdgeTop

Open in new window

0
 

Author Closing Comment

by:murbro
ID: 39924633
thanks very much
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying 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

This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial will demonstrate the scrolling table in Microsoft Excel using the INDEX function.

856 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