473,667 Members | 2,548 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to count occurrence of two cells value in a worksheet

1 New Member
I have an excel(2002) worksheet with 5 columns and 800 rows with random cells values. I would like to count how many cells in the worksheet have values like A1 & A2. For example, if A1=3, A2=11, C19=3, C20=11, A102=3, A103=11 then count value is 3. and so on.

Thanks for help.
Nov 14 '08 #1
2 1859
Frinavale
9,735 Recognized Expert Moderator Expert
Bump .
Jan 9 '09 #2
ADezii
8,834 Recognized Expert Expert
@jusking
  1. Wouldn't the Count Value = 4?
  2. Is this being done within Excel or Access?
Jan 10 '09 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

21
2502
by: rccf6178 | last post by:
Hi all, Do anyone know how to write a C program to count the frequency of a certain key pattern in a given datafile? Input: • Three alpha-numeric keys separated by space • A data file contains M by 3 matrix of alpha-numeric keys. Where M is number of rows and 3 is number of columns.
3
25319
by: Damian Arntzen | last post by:
I'm a beginner to moderate programmer who's fiddling around with automating Excel, in particular after being able to have the user fill out a form and it then generate the workbook. I can't quite figure out how to get it to Merge cells together - I've found how to do it (I think) but can't nut out the syntax. Any help with this would be much appreciated (I've tried looking for online tutorials, but the ones I've found never touch merging)....
1
4146
by: Howard Weiss | last post by:
I would like to set a particular cell in an Excel Spreadsheet to a specific value Visual Basic Equivalent would be Cells(row, column) = x where row and column locate the cell and x is the value In C++, I can execute code such as
5
3036
by: mrid via DotNetMonster.com | last post by:
hi. im exporting data from a vb form to excel. i am able to create a new excel file, save and edit it without any trouble, but the formatting is giving me hell! i need to be able to show certain cells in bold, with underlining etc. i dont understand how, but in the following code, the instruction for bold gets picked up for all the cells (even when i specify font.bold = false), and the underlining is haphazardly used. the font colour...
1
1757
by: Chris | last post by:
I'm sitting with a bit of an issue with pyExcelerator and creating an Excel file with certain cells protected while the rest of the spreadsheet is password protected. The Protection class under Formatting has 2 variables for cell_locked and formula_hidden, tbh I only need to alter cell_locked to 0 to make those cells writable but changing that on a global scale ends up with everything I write being "writeable" if you re-open the file...
2
4662
by: shantanu | last post by:
Dear All My requirement is to count the number of cells which are blank in a excel column, for that i am writing the following code;;;;;;;;;;;;;;;;; private void ValidateReviewComment() { //Range xlsRng = _sheet.get_Range("G1",Type.Missing).EntireColumn; //MessageBox.Show(xlsRng.EntireColumn.Count.ToString()); Range xlsRng = _sheet.UsedRange;
0
1374
by: Tetravaal | last post by:
I normally don't ask for help on forums, especially when I know that I am WAY out my league but if your feeling kind, feel free to contribute! I need to compare two cells (D2 and D3) and if they match a certain result then copy some cells associated to them to a new worksheet, and then move on to the next row and repeat until there is no more data (Blank Cells). So lets say in cell D2 I have "Personal" and in D3 "Break", if that statement...
4
15480
by: ielamrani | last post by:
Hi, I am getting this error when I try to export to an excel sheet. When I click on a button to export the first time it's fine, I rename the exported excel sheet and I try to export it again and I get the error: Runtime Error 1004: Method ‘Cells’ of Object ‘_Global’ failed It highlight this line: Range("A1:L1").Select sorry the code behind the button is long: . Dim stDocName As String stDocName = "QFinal4"
1
5165
by: bluejeanbaby | last post by:
Hi I'm trying to format an Excel file from within VB.NET 2008 (Framework 2.0). I'm not very familiar with Excel but have taken existing working code from an old VB6 program and am "tweaking" it to get it to work in VB.NET. I have most of it working with the exception of the following lines: rng = ws.Range(xclApp.Intersect(ws.Rows(7).EntireRow, ws.UsedRange.Columns(1)), ws.UsedRange.SpecialCells(XlCellType.xlCellTypeLastCell))...
0
8454
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8883
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8787
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8561
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7389
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5672
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4200
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4372
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2776
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.