Over 1 million tech questions and answers.

Show/Hide columns based on cell contents

Q: Show/Hide columns based on cell contents

Hi Guys,

Apologies for repeating an old question, but I am trying to build my spreadsheet so that it auto-hides any rows were there is zero premium outstanding for a client.

I had gone through previous answers, and I had tried to lift and amend some VBA code to achieve this. However, somewhere within this code or the way I've implemented it, there is an error, because it's not showing of hiding any rows.

Can you please take a look at the attached and fix it (in order to hide all rows with a zero in column C), and maybe point out what I was doing wrong or omitting. I have anonymised my data.

Many Thanks
John

RELEVANCY SCORE 200
Preferred Solution: Show/Hide columns based on cell contents

I recommend downloading and running Reimage. It's a computer repair tool that has been proven to identify and fix many Windows problems with a high level of success.

I've used it in the past to identify and fix everything from blue screens (BSOD's), ActiveX errors, corrupt files and processes, dll/exe/sys errors, recover lost memory, Windows update problems, defragging, malware removal etc.

You can download it direct from this link http://downloadreimage.com/download.php. (This link will automatically start a download of Reimage that you can save to your computer.)

A: Show/Hide columns based on cell contents

Apologies... the criteria column is actually F, not C, the "outstanding premium" column. The intention being to display only those rows where client still owe premium

Read other 1 answers
RELEVANCY SCORE 118.4

Hi guys,

Can you please help me further expand the macro below? I need it to also look between the ranges of C24 and Z24 and hide the respective column. (i.e need some sort of loop)

i.e

if C24 is 0, then hide column C
if D24 is 0, then hide column D
etc...
Sub Hide_Column ()

If Range("H24").Value = 0 Then
Columns("H").EntireColumn.Hidden = True
Else
Columns("H").EntireColumn.Hidden = False
End If

End Sub
 

A:Solved: Hide Columns based on value of cell

Read other 9 answers
RELEVANCY SCORE 94.4

Hello,

I am attempting to clear 2 cells, based off the value of another. I am pretty sure the code is correct, because it works within another Macro. Thanks.
Code:
Sub REMOVE()


Dim p As Long
p = Cells(Rows.Count, "a").End(xlUp).Row


For i = 1 To p
Range("k2").Select
If InStr(1, Range("k" & p), "None") > 0 Then Range("L" & p) = "" And Range("M" & p) = ""
'If no Issue, Location/Obsevations should be blank
Next i


End Sub


 

A:Solved: Clearing Cell Contents Based off other Cell

hi
try this variation;
Sub REMOVE()

Dim p As Long
p = Cells(Rows.Count, "a").End(xlUp).Row

For i = 1 To p
If InStr(1, Range("k" & i), "None") > 0 Then
Range("L" & i) = ""
Range("M" & i) = ""
End If
'If no Issue, Location/Obsevations should be blank
Next i

End Sub
 

Read other 2 answers
RELEVANCY SCORE 86.8

Hi All,

I need to make a macro that will add borders to certain cells.
I have a generated report from another product so I don't know how many rows there will be until the report is generated. The number of rows is specified inside the report, so I do have access to it. It is stored in cell C5.

So what I want to do is add borders around C5 number of rows starting at A7..E7

I tried using a rule, to just put borders around cells that contain data, but that won't work because sometimes cells are blank and I still want the border around them.

Help?! Please

Thanks a bunch!!!
Lori
 

A:Excel Macro to add borders based on cell contents?

Hi Lori

Here is a macro that will take the value in C5 e.g. 10 and then apply borders to all cells in A7 to E16
Code:
Sub add_borders()
lRow = Range("C5") + 6
Range("A7:E" & lRow).Select
Selection.Borders(xlDiagonalUp).LineStyle = xlNone
With Selection.Borders(xlEdgeLeft)
.LineStyle = xlC9ontinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlEdgeTop)
.LineStyle = xlContinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlEdgeRight)
.LineStyle = xlContinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlInsideVertical)
.LineStyle = xlContinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlInsideHorizontal)
.LineStyle = xlContinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
End Sub
 

Read other 1 answers
RELEVANCY SCORE 86

Hi,
I am trying to hide rows in excel 2010 based on cell values in a certain column. I know that I have to use the VBA but I don't know how to do that kind of stuff. I know it should be simple to do but I don't know where to start. Let me know what you need in order to help me accomplish this task.
 

A:How to hide rows in excell based on cell value

Read other 8 answers
RELEVANCY SCORE 85.2

Hello to evrebody,
I have look into the answers and the solutions about "hide/unhide rows based on the cell data" but i am not abble to understand how its work and apply to my sheet.
On theattached sheet i explain what im looking for.
Pleaseo play it and hope to help me and give a solution please.
Thanks in advance.
Jose
 

Read other answers
RELEVANCY SCORE 85.2

Hey all

New here and new to VBA so I apologize if this is the incorrect place to ask this question or if I'm not including enough information.

Basically I have two forms, one form that is a cost est. form and another form is a proposal form (client sees this one). I have the proposal form pulling information over from the cost est. form. What I would like to do is on the proposal form if rows c13:c277 are blank (no data pulled from the cost est. sheet) they will hide. But when I add data (a number) into the cost est. form the proposal form pulls that and unhides that row.

I've tried all kinds of VBA code and none seem to do what I want. I can get the rows to hide but then not unhide. I don't have code to show because I have deleted it when it didn't work. Any help would be greatly appreciated.
 

Read other answers
RELEVANCY SCORE 85.2

Hey all

New here and new to VBA so I apologize if this is the incorrect place to ask this question or if I'm not including enough information.

Basically I have two forms, one form that is a cost est. form and another form is a proposal form (client sees this one). I have the proposal form pulling information over from the cost est. form. What I would like to do is on the proposal form if rows c13:c277 are blank (no data pulled from the cost est. sheet) they will hide. But when I add data (a number) into the cost est. form the proposal form pulls that and unhides that row.

I've tried all kinds of VBA code and none seem to do what I want. I can get the rows to hide but then not unhide. I don't have code to show because I have deleted it when it didn't work. Any help would be greatly appreciated.
 

Read other answers
RELEVANCY SCORE 85.2

Hi all, long time reader, first time poster. I searched around and have found similar queries to what I require however I haven't been able to adapt these solutions with any success so here we go....

I have a list of businesses in a spreadsheet with information such as name, phone number, e-mail, website, postcode etc. I would like a search box on the side, say in cell O2 where a user can input part or all of a postcode e.g. (LS19 or LS) and those that do not begin with LS would be hidden. The postcodes are in column G.

I'm trying to make this as simple and user-friendly as possible so employees can find businesses in a certain area with ease. Thanks in advance for any help and please feel free to ask questions.

Chris Needham
 

A:Excel VBA : Hide rows based on cell input.

Seems nobody had the answer so I found a work around myself. Just in case anybody else wants to do a similar thing. Using auto filter is the easiest way.
Code:

[SIZE="3"]Sub Search()
Columns("G:G").Select
Selection.AutoFilter
ActiveSheet.Range("$G$1:$G$999").AutoFilter Field:=1, Criteria1:="*" & Range("O2").text & "*", _
Operator:=xlAnd
End Sub[/SIZE]

Where G is the column to search for and O2 is the users input data.

Guess this can be closed now, thankyou all for your help.
 

Read other 1 answers
RELEVANCY SCORE 84

I have built a simple timesheet for someone in my dept, which includes amongst other things:

- hours worked over a month,
- how many hours owed/extra worked
- a cumulative of this figure over the months.

The requestor wants to be able to type a letter such as 'e' to represent a 07:30hr shift. So they type 'e' and the cell contents change to 07:30. There are about 6 different codes.

Normally a Vlookup would work EXCEPT you can't change the contents of the cell your are working upon.....cicrular referencing!

I could see two ways forward: either a function that allows the above

OR (perhaps more favourably)

leaving the lookups until the hour calculations at the base of the form. i.e Instead of a simple Sum for the hours worked that month, it could read the values in the range, look them up from a table(vlookup), and then sum the looked up figures to give the answer in the 'hours worked' cell.

I vaguely remember this being possible from my university days but can't remember how.

Can anyone help me?
 

A:Excel 2003: automatically changing a cell's contents based on keyword entered

Read other 9 answers
RELEVANCY SCORE 80.4

How do I hide and show different columns based on values selected from a drop-down list? I wrote a code to do this but there has to be an easier way.

Cell C2 has a drop-down list. This list is from another part of the workbook. Next to the list in the workbook, I put values representing the beginning of the columns I want to Show.

Units 4
Intervals 5
Time 6
All 0

On the page that I am working with I have created a spreadsheet that tracks monthly amounts of Units, Intervals and Time (in separate columns). I want to be able to select "Units" from C2 and show columns, 4, 7, 10, 13... +3 each) then be able to show Intervals (and only show columns 5, 8, 11, 14... etc), then Time (and show columns 6, 9, 12, 15... etc) and if I select All, I want to show everything.

Dim x As Integer
Dim vCriteria
vCriteria = Range("C4")

If vCriteria = "0" Then
Columns("D:AS").Select
Selection.EntireColumn.Hidden = False

Else
Columns(vCriteria).Select
Selection.EntireColumn.Hidden = False

Columns(vCriteria + 3).Select
Selection.EntireColumn.Hidden = False
Columns(vCriteria + 6).Select
Selection.EntireColumn.Hidden = False
Columns(vCriteria + 9).Select
Selection.EntireColumn.Hidden = False
'... and repeat til vCriteria + 40 (column AS)

End If
End Sub

This works. But....
There has to be an easier way to write this code. Additionally, I want to be able to add more more columns to this spreadsheet as it is tracking monthly numbers so I don't wa... Read more

A:Excel VBA: Show/Hide rows based on dropdown value

Read other 8 answers
RELEVANCY SCORE 70.4

I'm attempting to write my first macro for an Excel 2003 workbook. I'm not completely code illiterate (I've got moderate skills with AutoLISP), but I'm new to VBA and am not yet an Excel power user, so please be gentle.

The macro I want to write will:
check that the selected cell's content is underlined before proceeding
copy the content of the currently selected cell into an external plain text .log file
.log file lines should be: year/month/day - time - username - cell contents
.log file names will probably need to be generated
clear the cell's content and formatting (particularly underline and text/background color)
Here's what I have so far:
Code:
Sub Unpost()
If Selection.Font.Underline = True
Then Selection.ClearFormats And Selection.Clearcontents
Else
If MsgBox("The selected cell is not underlined...are you sure?", vbOkCancel) = vbOk
Then Selection.ClearFormats And Selection.Clearcontents
Else Exit Sub
End If
End If
End Sub
If I've written it correctly, it should currently do everything except log the cell contents. This, from what I've seen, is going to be the trickier part. I intend to use this macro 50+ times per weekday, so at some point the .log files will get too long to be useful, so I assume it will need to automatically create new logs (perhaps "year-month.log"). I've seen some useful info about appending to an external log here and here, ... Read more

A:Excel 2003 macro: log contents of selected cell, clear cell

You need to use the "File Scripting Object" to create and/or append text to a file. I've included a link below to get you started. If you are unable to figure it out on your own let me know and I'll write the code for you.

http://www.virtualsplat.com/tips/visual-basic-fso.asp

Rollin
 

Read other 1 answers
RELEVANCY SCORE 69.2

Using Excel 2003 in Windows XP

I would like to use the contents of one cell as the destination location for copying data.
For example
I have 2 worksheets 1) Results and 2) info
in info
A1 = 'ABC'
C1 = 'Results!O54' < this is calculated based on other data in sheet.

Using a macro, I'd like to copy contents of A1 to cell location 'Results!O54' more specifically to where ever C1 points... C1 will change based on other data in info sheet.

The macro record for action looks like this (but I would like the 'O54' to be based on contents of C1 which changes)
Range("A1").Select
Selection.Copy
Sheets("Results").Select
Range("O54").Select
ActiveSheet.Paste
Sheets("info").Select

There is more to it then that but I think this is where I am stumped.
 

A:Solved: Excel: Uses contents of Cell to select a cell

Sheets("info").Range("A1").Copy Destination:=Sheets("Results").Range(Sheets("info").Range("C1").Value)
 

Read other 3 answers
RELEVANCY SCORE 68.4

I have a sheet set up with the list with the description (text) in column B, and summary scores (numerical, percentage) in column D. I want to do a summary row at the top of the sheet that pulls the data from the B cells, based on the lowest 3 values in column D.
 
I plan on using the formula =SMALL(D7:D32,1) (with d7:d32 being the list of percentages), to figure out the lowest 3 values. But the formula just pulls the summary score, not the description. I want to pull the description into but I am at a loss.
 
I am using excel 2013 on windows 10. Any help would be appreciated.

Read other answers
RELEVANCY SCORE 68.4

I have a sheet set up with the list with the description (text) in column B, and summary scores (numerical, percentage) in column D. I want to do a summary row at the top of the sheet that pulls the data from the B cells, based on the lowest 3 values in column D.
 
I plan on using the formula =SMALL(D7:D32,1) (with d7:d32 being the list of percentages), to figure out the lowest 3 values. But the formula just pulls the summary score, not the description. I want to pull the description into but I am at a loss.
 
I am using excel 2013 on windows 10. Any help would be appreciated.

Read other answers
RELEVANCY SCORE 68.4

Hello,

I cant seem work out a solution for what I'm trying to do. I have an Excel workbook that has multiple sheets. On sheet 1 i want the data from cell "G3" to be copied onto sheet 2. But i want the location on sheet 2 to be based on whatever was entered into cell "D3" on sheet 1.

For example: Sheet 1, cell D3 I have the name John, in cell G3 i have 68. I want "68" to be pasted in sheet 2 in cell B26.

But if the name in Sheet 1 cell D3 is Suzie, then I want G3 to be pasted in Sheet 2 in cell D26. So I would need to identify the paste location for each person.

I want the data to paste to the next cell so that the next entry can be pasted below the last entry for that person (for John the first entry would go into cell B26, then the next entry would go into cell B27 and so on).

But i want it to be a specific range, i dont want data to be pasted past 20 cells (cell B45). If possible a message box could be created to let the user know that the max is reached.

I would appreciate anyone's help with this as i have been struggling for awhile to try to get this. Thank you
 

A:Excel - Copy paste cell into range based on another cell

Read other 12 answers
RELEVANCY SCORE 62.8

I want to hide a few columns on a spreadsheet after I run a macro. I'm familiar with making sheets visible and hiding them with a macro, but not sure I know how with columns. Any help.
 

A:Solved: How to hide columns

Set the width to 0? That will effectivly hide them.
 

Read other 3 answers
RELEVANCY SCORE 62.8

I have multiple (80 or so) sheets were I what to hide certain columns say I:N on all sheets not just the active sheet with out a very length code! Can any1 help.

Sub hidealltest()
Dim ws As Worksheet
For Each ws In Sheets
Columns("I:N").Select
Selection.EntireColumn.Hidden = True
Next
End Sub

It only works on active sheet but highlights all columns to be hidden in sheet 2 and 3 but fails to hide them..
 

A:hide certain columns in all sheets

I posted in wrong place by mistake then it got moved after I made a new 1 sorry
 

Read other 2 answers
RELEVANCY SCORE 62

Here is a sample of the table that I am working with:

Year Warehouse Item# Period1 Period2 Period3 Period4 etc....

There are many more columns but my issue is that if there is a 0 or blanks for all columns from period 1 to period 12 then don't show that row. How do I get this to happen with a query?
 

A:Access - hide row if many columns contain same data

In the first Criteria row for each period column enter
>0
 

Read other 1 answers
RELEVANCY SCORE 61.6

Is there an easy way to only count instances where two columns have two different values?

Example: I want to count instances where Column A = "Test" AND Column B = "Evaluate". If either column is not equal to that value, it doesn't get counted, even if the other column is correct.
 

A:countif based on values of 2 columns

Read other 12 answers
RELEVANCY SCORE 61.2

I work on parts lists at work that have ben created by colleagues. They have approximately 80 columns. I need to refer to these parts lists when completing a separate excel file and I want to be able to hide certain columns. The columns that I want to hide are not beside each other so I can't use the *group* function. Well I suppose I could use it but I?d prefer to use a Macro as I'm sure it would be moe efficient.

I?m not up to speed with VBA and I?ve been attempting to record a Macro but have only been partially successful thus far. So on the attached is my macro recording effort. I wanted to hide columns G, T, AC, AF, AX and BA. In order to do this I am doing the following

View Tab > Record Macro
Enter macro name and description
Shift select columns G, T, AC, AF, AX and BA
Right click and hide them
Click on Stop Recording
I thought this would be sufficient. However, when I go back and run the macro it hides columns A:L, T, AC, AF, AX and BA. Can anyone show me what I?m doing wrong or is my understanding of how a macro works different to reality.

Moving on from this I would like to be able to do the opposite, i.e. unhide above columns (actually this macro works in the attached). Would also be very handy to have buttons that I could just click on that would do this.
 

Read other answers
RELEVANCY SCORE 61.2

I found this code to hide certain columns when any cell in Column C is double clicked.
Code:
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If Target.Column = 3 Then
Range("D:D").EntireColumn.Hidden = Not Range("D:D").EntireColumn.Hidden
Range("E:E").EntireColumn.Hidden = Not Range("E:E").EntireColumn.Hidden
Range("S:S").EntireColumn.Hidden = Not Range("S:S").EntireColumn.Hidden
End If
End Sub
What I would like is for code to hide columns if any cell in columns between A:AA(27 columns) is double clicked.
Thanks
Pedro
 

A:Help with macro to hide columns with double click

You edit the If ....

In this case If column B through column Z
If Target.Column > 1 and Target.Column < 27 Then

Just play with the If staemenet.
 

Read other 3 answers
RELEVANCY SCORE 61.2

Hello
I am running win 7 and and I've noticed that the folder columns change based on the content of the folders. For example, when I'm looking at a folder with documents in it, I have the following columns:
Name
Date Modified
Type
Size

When I go into a folder with mp3s:
Name
Track number
Title
Contributing artists
Album

For pictures:
Name
size
type
date
date modified

I'd like to have all folders have the same columns no matter what files are in it. I've tried using Tools->folder options->view-> apply to folders button, but it does not fix the issue. Any way to change it for all folders?
Thanks

A:Folder columns change based on content

Hello Bandit, and welcome to Seven Forums.

This can help show you how to set a default folder view to be used in all folders in Windows 7.

Folder View - Set a Default for All Folders

Hope this helps,
Shawn

Read other 1 answers
RELEVANCY SCORE 60.8

Greetings,

I am using MS Excel 2007.

My situation is as this

I run a report every week for some items and their value, I compare 2 conditions. Condition 1 gives the whole list with Column A as the name of the item and Column B with value of the item.

Condition 2 is for the same items but the problem is that when I extract the data from SAP it excludes the item name that has 0 or less value, so i don't get the whole list of items.

And both conditions go in the same woorkbook and sheet when I run the report (I copy them into one workbook. The report is for comparing between condition 1 and condition 2.

The problem is that I have to go through both lists of items and manually add the items that are missing in condition 2 and add a value of zero next to them.

I need a macro that compares the conditions and not only add the missing item name but also add zero to the cell next to the item added ( to the right)
 

A:MS Excel 2007 Compare Columns and add to next cell

Sorry for bothering... I must have put this in the wrong place

I solved the problem... Needed an iPod with some of the best of Yanni and a couple of cigarettes to come up with a solution

I was thinking that the "IF" formula is the solution but what I needed actually was advanced filtering.

Item name on Column A and value in Column B

Sorted both Conditions by Column A

Condition 1 has the full list of items.. and Condition 2 had a smaller list but needed to have all items and the missing ones needed to have 0 value in B.

I had a new workbook and copied Columns A & B from Condition 2 into the new workbook. Then went to condition 1 and copied column A only under the cells copied from Condition 2.

Used advanced filtering on Column A to show unique records only.

The result is a list of items with their values in column B untouched and the ones that were missing in Condition 2 had blank value.

Now I can run a macro to automate this process...

Sorry for having this put in the wrong place, and it seemed that I was able to solve this on my own after all.

Well the bright side is that there is a one in a million chance that someone out there need the same thing that I need and actually see a solution
 

Read other 1 answers
RELEVANCY SCORE 60.8

Hi All,

I have a requirement. I have multiple values in a single cell. They have to be splitted to adjacent cells(next columns). The problem is there are no standard delimiters,there are diffferent delimiters in the same cell.

Example:
Input:
ColumnA
Row1: {Product} (Accumulator) Section Benefit, Period has invalid value : 24 Months

Output:
ColumnA ColumnB ColumnC ColumnD
Row1: {Product} (Accumulator) Section Benefit Period has invalid value 24 Months

Like this there are some 40000 rows.

Note: You can use that "(Accumulator)" as a delimiter. It ll be present in all the rows.

Thanks in advance.
 

A:Need a Macro to Split a cell into multiple columns

Can you post a workbook with a few rows of sample data?

Rollin
 

Read other 1 answers
RELEVANCY SCORE 60.8

Hi Again

CodeLexicon gave me a code that worked very well in hiding column A only. Is it possible to make the macro hide all columns with all zeros?? Also I tried to change CodeLexicon's macro to do hide all rows whose columns have zeros but without success. I tried to make the code generic.

Attached is a workbook with the 2 macros. Test the macro that I did out and see that it only hides row A only.

Mario
 

A:Solved: Macro to hide all rows whose columns have zeros

Read other 6 answers
RELEVANCY SCORE 60.4

I am trying to write a macro that compares cells in column A from sheet1 to cells from column A in sheet2 and if the values from sheet2 are not in sheet1 then I want to delete the entire row from Column A in sheet2.

for example

In sheet1, column A has a list of id no's (no duplicates) and in sheet2 Column A has list of id no's (with duplicates). I want to delete every row in Sheet2 Column A that is not in Sheet1 Column A.

Keep in mind that both sheets have several columns.
Also there is about 5000 rows in sheet 2

Any help would be greatly appreciated.

Thanks
 

A:Excel HELP macro to Delete Row Based 2 columns from 2 sheets

Welcome to the board.

While I understand each part of your post (I think), some parts seem to contradict others. So here's what I did.

In Sheet1!A1:A5 I entered 1 -- 2 -- 3 -- 4 -- 5.

In Sheet1!A1:A6 I entered 1 -- 2 -- 6 -- 3 -- 4 -- 5.

Then I wrote some code that removes the third row from Sheet2, since it contains 6 in column A which is not in col A of Sheet1.

How the code works is:

(i) inserts a new column A on Sheet2

(ii) enters a formula in new column A Sheet2, e.g.:

=MATCH(B1,Sheet1!A:A,0)

which returns a number if there's a match in column A Sheet1, #N/A if not

(iii) deletes any rows on Sheet2 with #N/A in column A

(iv) deletes column A on Sheet2 (redundant).

Obviously if this isn't what you need don't use it, post more info instead.

HTH

Sub test()
Sheets("Sheet2").Range("A1").EntireColumn.Insert
x = Rows.Count
y = Sheets("Sheet2").Range("B" & x).End(xlUp).Row
Sheets("Sheet2").Range("A1").Resize.FormulaR1C1 = "=MATCH(RC[1],Sheet1!C,0)"
Sheets("Sheet2").Range("A1").Resize.SpecialCells(xlCellTypeFormulas, 16).EntireRow.Delete
Sheets("Sheet2").Columns(1).Delete
End Sub
 

Read other 1 answers
RELEVANCY SCORE 60.4

If in cell A1, the user was able to write a cell number of their choice, say B5.
In the cells that they would be choosing, would be numbers. In cell A2, I want to use the contents of the cell that the user has typed into A1. Not the contents of A1, but the contents of the cell that has its cell number in A1. In this case, I would want to use the contents of B5. There will be around 15 boxes in which the user is free to write any cell number they choose. Then, in the formula box (A2) I would read the contents of these cells, and if something was there get its contents and then use the cell number that it says in a sum, in which the numbers in all of the cells which the user has chosen were added up.
What could I do?
 

A:Excel 97 Cell Contents

Read other 9 answers
RELEVANCY SCORE 59.6

Does any one know how to create a Formula or Function that would recognize whether the contents
of a cell are a hard coded value versus a formula ?
 

A:Excel Cell Contents Recognition

http://www.j-walk.com/ss/excel/tips/tip28.htm
 

Read other 2 answers
RELEVANCY SCORE 59.6

I can't edit the cell contents in ms office excell 2007.
please help.

A:I can't edit the cell contents in ms excell

Moving thread to the Office Forum for better results.
What does the formula say in the Formula Bar? If you Right click the Cell and choose Format Cells what is listed under the various categories (ex) Number, Currency etc. Is this only pertaining to this particular work book or is this in all work books?

Read other 1 answers
RELEVANCY SCORE 59.6

Hi,
I have a cell that contains 1st and last names seperated by a "space". I want to seperate them (1st and last) into 2 seperate cells.

Example:
Cell A1 contents = John Smith
After seperation
Cell A1 = John SMith
Cell B1 = John
Cell C1 = Smith

Your help would be greatly appreciated! Even if it's just pointing me in the right direction. THanks. Excell 2000
 

A:Excell - seperate contents of a cell

Read other 11 answers
RELEVANCY SCORE 59.6

Excel 2007 users having an unusual problem of cell content temporarily disappearing. Content shows in formula bar, but not in cell unless the cell is highlighted or double clicked, then contents reappear. This is completely random with no discernable pattern except that it seems to happen most often when scrolling. I've found this same question in multiple places on the web, but no solutions. Any suggestions on cause and cure?
 

Read other answers
RELEVANCY SCORE 59.6

I cannot find this question on Search, so I'm hoping it's so basic that I'm the only one who doesn't know how to do it. . .Norton scan informed me I had 2 adware threats and instructed me to delete them by tracking them to my System32 folder and deleting them, which I did. My question now is how do I once again change that folder's contents back to "hidden" so they are not accidentally accessed and screwing up my computer? Thanks.
 

A:Solved: Hide System32 folder contents again

Read other 9 answers
RELEVANCY SCORE 59.2

I need to delete multiple columns within an Excel worksheet based on the headers in the first row. What would be the best way to perform this operation?

I have been playing around with the code below, but I feel as though there could be a better way.

Sub test()

Dim myArr As Variant

myArr = Array("Test1", "Test2", "Test3")
If Range("C1").Value = myArr Then
Columns("C").Delete shift:=xlToLeft
ElseIf Range("D1").Value = myArr Then
Columns("D").Delete shift:=xlToLeft
End If

End Sub
 

A:Solved: Excel Macro -> Delete Multiple Columns Based on Criteria

Read other 16 answers
RELEVANCY SCORE 59.2

Hi,

I use two sheets to manage my client list in Excel 2007. One is my calling list where all my companies along with the point of contacts' names, numbers, email, postal addresses are listed. Another one is a strategy list (which I update on biweekly basis) where I have written the current strategy against each company.

What I want to do is to show the strategies I have updated in the 2nd sheet to appear in the comment of companies of the 1st sheet so I know how to handle the customer while I am making the call to him/her.
 

A:Get cell contents in the form of comment in another sheet

Read other 8 answers
RELEVANCY SCORE 59.2

Hi

I have a lot of cells in a worksheet that I would like to edit. The cells have this type of data 08:59:39 AM and I would like to change it to '08:59. When I record a macro it changes all the cells to the same value although they have different values. Please could you assist me.

Thanks
 

A:Edit cell contents in excel 2003

Read other 8 answers
RELEVANCY SCORE 59.2

Hiya,

I'm having to make a list of users that we have but I need to put in name and login for example

Matt Hobbs | Mhobbs

Is there a forumla that I can use to read Cell A1 (Matt Hobbs) to display Mhobbs? so read the first character of the first word, then read the whole of the second word within a cell? - I've got no idea if its possible or not.

Thanks,
Matt
 

A:Excel formula to read the contents of a cell

Hi Matt, try this formula in B1
Code:

=LEFT(A1,1) & RIGHT(A1,LEN(A1) - FIND(" ",A1,1))
 

Read other 3 answers
RELEVANCY SCORE 59.2

I have a 5x7 table in Excel 2016 with a named range "CellsToAlign" and I want to be able to automatically format the cells to align the contents LEFT or RIGHT dependendent upon the cell value being a Negative or Positive value ?
 

Read other answers
RELEVANCY SCORE 59.2

I would like to have some code whereby when the workbook is saved, it will check certain cells for their content. If the content meets the criteria, the workbook will save. If not, a message box will appear. Its like using the validation function, but only when the workbook is saved. For example – if cell A1 has an entry, then cell B1 must also have an entry otherwise it won’t allow saving. Any ideas?
 

A:Solved: Check cell contents at Save

Read other 16 answers
RELEVANCY SCORE 59.2

I have an excel spreadsheet. I would like to copy the contents of the table to word but I do not want it to be in a table on the word document. Even hiding gridlines does not work because I still cannot maniputate information in the cells. Is there any way to make the table inactive?

For example:
With gridlines hidden it looks like

Blah Blah Blah Blah

and I want it to look like
blah
blah
blah blah

i could cut each cell but that would take forever because I have 6 columns
and 160 rows.
 

A:EXCEL to WORD copying cell contents

Read other 12 answers
RELEVANCY SCORE 59.2

Hi, I need a formula (=if etc.) to add a leading "0" if the contents of a cell are only 4 character.

SOrry, never mind. I started this tread in error and need to figure out how to delete it.
 

Read other answers
RELEVANCY SCORE 58.4

How does one create a mail merge document that will print only certain paragraphs or sentences based on data in each record? For example, a mail merge document where you wanted the first paragraph to be one thing if [fieldx] is "yes" and something else entirely if [fieldx] is "no"?
 

A:Word: Mailmerge Letter Contents Based on Field Value

Check here, Don:

http://www.mvps.org/word/FAQs/MailMerge/MMergeIfFields.htm
 

Read other 3 answers
RELEVANCY SCORE 58.4

I have a fairly simple task. From Row 17 to row 51 and Row 96 to 163 , I want to delete the row if cells P and Q are empty.

From row 57 to row 94 I want to delete the row if cells B, C, P, and Q are empty

I'm not sure what I'm doing wrong here.

Sub CleanUp()

Dim endrow As Long
Dim x As Integer

Set endrow = Sheets("Work Order").Range("A17").End(xlUp).Row

For x = endrow To 17 Step -1
If Sheets("Work Order").Range("P" & x) = "" And Sheets("Work Order").Range("Q" & x) = "" Then Sheets("Work Order").Rows(x).EntireRow.delete
End If
Next x

Rows("167:180").Select
Selection.delete shift:=x1Up
End Sub
Click to expand...

If you see something glaringly wrong or know a quicker way to do this, I would be very thankful.
 

A:VBA Deleting row based on cell value

Here's an example work sheet. If the code works right in the example, it would delete rows 4, 5, 9, and 10.

Code:
Dim endrow As Long
Dim x As Long

For x = endrow To 29 Step -1
If Sheets("Sheet1").Range("P" & x).Value = "" And Sheets("Sheet1").Range("Q" & x).Value = "" Then
Sheets("Sheet1").Rows(x).EntireRow.Delete
End If

Next x
Why won't it remove the rows?
 

Read other 2 answers
RELEVANCY SCORE 58.4

I have a spread sheet where I would like a message to pop up after I enter a value in cell G2 based on what the value of I2 is. like the following description:
In cell I2 I have "=(E2*F2*G2)/144" after I enter a value in cell G2 I want a message to come up if the value of I2/g2 is less than three and not equal to zero" Is this possible? If so could someone help me out with this?

thanx
 

A:validation based on another cell

This is the same as the challenge file but I added the code for this question
 

Read other 1 answers
RELEVANCY SCORE 58.4

I have an excel workbook with a "INPUT" WkSht, and a "ACTIVE" WkSht.
INPUT has a dropdown menu that looks up a list in ACTIVE, locates a desired value, and displays several cells contents in ACTIVE, - in the INPUT page.
This is working.

Question 1:
One cell in ACTIVE contains "comments" - how do I display the comments in the cell from ACTIVE, in a cell in INPUT - so I can look at all of them.

Question 2:
How do I update the contents of a cell in ACTIVE, at the same location that was selected from the dropdown.

I am a beginner - please help.

See present MACRO below...

Sub UpdateLogWorksheet()

Dim historyWks As Worksheet
Dim inputWks As Worksheet

Dim nextRow As Long
Dim oCol As Long

Dim myRng As Range
Dim myCopy As String
Dim myCopy2 As String
Dim myCell As Range

'cells to copy from Input sheet - some contain formulas
myCopy = "D5,D6,I18,D20,D19,D8,D10"
myCopy2 = "D5,D6,D7,D8,D9,D10"
Set inputWks = Worksheets("Input")
Set historyWks = Worksheets("Payments")

With historyWks
nextRow = .Cells(.Rows.Count, "A").End(xlUp).Offset(1, 0).Row
End With

With inputWks
Set myRng = .Range(myCopy)

If Application.CountA(myRng) <> myRng.Cells.Count Then
MsgBox "Please fill in all the cells!"
Exit Sub
End If
End With

With historyWks
With .Cells(nextRow, "A")
.Value = Now
.NumberFormat = "mm/dd/yy"
End With
.Cells(nextRow, "B").Value = Application.UserNam... Read more

A:Excel Marco Dropdown Menu Cell Contents

please do not duplicate
As your other post is in the Business Applications forum
continue there
http://forums.techguy.org/business-applications/899510-excel-marco-dropdown-menu-cell.html

closing this post
 

Read other 1 answers
RELEVANCY SCORE 58.4

Hi all,

Cell A1 has value One
Cell B1 has value Two
Cell C1 has value Three

My requirement is to compare the contents of Cell A with Cell B and blank out contents of Cell C if contents of A <> contents of B.

I have written the formula like this:
=If(A1=B1,"",C1="") This assigns a value of True or False to cell C1 based on the values of A1 and B1.

I have also used
=If(A1=B1,"",C1=" ") The same result.

I need to blank out the contents of cell C1 completely without using any macros.
 

A:Making the contents of a cell blank in excel without macros

If you want C1 EMPTY then this is an impossible task. It needs macros.

If you merely want it to look empty then it's as simple as putting =If(A1=B1, X ,"") where X is the contents you want in C1 when the two are equal.
Or you could leave the original contents in the cell, and add conditional formatting to C1 whiting out the cell if the two are equal.
 

Read other 2 answers