Solved

VB.net Excel Add-in Second value or tag for a cell

Posted on 2014-03-12
5
520 Views
Last Modified: 2014-03-13
Hi
I need to put some hidden information behind a cell, like a tag of sorts
I used the following but that just updated the actual cell value

 Globals.ThisAddIn.Application.ActiveCell.Value2 = oResult
0
Comment
Question by:murbro
  • 2
  • 2
5 Comments
 
LVL 14

Expert Comment

by:Zack Barresse
ID: 39925599
Unfortunately there is no such thing as meta data for cells. You could store information in your application settings. Or create a temporary, hidden sheet to store your data. Or even write it to a text or config file.
0
 
LVL 45

Expert Comment

by:aikimark
ID: 39925601
What type of data do you need to associate with a cell?
0
 

Author Comment

by:murbro
ID: 39925611
I just want to associate text data
0
 
LVL 45

Accepted Solution

by:
aikimark earned 500 total points
ID: 39925691
I would agree with Zack's assessment that a hidden worksheet might be the easiest implementation.

===============
Alternatively, you can use the cell's .ID property
Example:
Activecell.ID = "Now is the time for all good men"

Open in new window


===============
If it were feasible, you could disable visible notes (an option) and assign the .NoteText property of a cell.  The text is there, but the user wouldn't see the triangle indicator and the fly-out textbox wouldn't appear.

You might also do this with the .Comment property.

===============
You might also use the custom document properties (.CustomDocumentProperties) of the workbook to store data.  You would probably include the cell address followed by the text.
0
 

Author Closing Comment

by:murbro
ID: 39925796
Great answer. Exactly what I needed
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

Improved? Move/Copy Add-in Replacement - How to avoid the annoying, “A formula or sheet you want to move or copy contains the name XXX, which already exists on the destination worksheet.” David Miller (dlmille)  It was one of those days… I wa…
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

828 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