Condensing 1000's Of Columns Into Just 3
May 20, 2008Based on the 1st example below, I have a file with 1000's of columns where every 3 columns has the same type of info....
View 9 RepliesBased on the 1st example below, I have a file with 1000's of columns where every 3 columns has the same type of info....
View 9 RepliesAm working with a spreadsheet of about 1000 rows and 50 columns which I need to transform into 2 columns and as many rows as needed. I have attached a simplified example of a 3x3 spreadsheet so you can see what I mean. I have already managed to get my result using Filtering and some copy and paste but I am struggling to now fully automate the solution.
View 4 Replies View RelatedI have multiple rows in my files that have duplicate information save for one line of information as such.
View 12 Replies View RelatedI want to ask if there is a way to simply extract non-empty rows from a data set consisting of many rows filled with zeroes and some which are filled with the non-zero values. By “simply” I mean without using any macros. Any help or suggestions are highly appreciated.
Dima
I have attached the workbook with example of the sheet with such data set (CLEAN tab shows the desired result of this operation):
[url]
We have a large table on one worksheet that has specific information that we want on a second worksheet.
We can use VLOOKUP to get one line of information transferred over to the new worksheet, but how to bring many lines of data over.
In the attached example, we want ONLY the RE or RO or RL lines of data in worksheet "ALL CREDIT CARDS" to be listed on the new worksheet "RE RO RL CREDIT CARDS".
Let's assume, starting at A1, that i have table (8c x 30r)
and lets assume that in each of the columns i have 5 cells filled in with data at random.
What is the best way for me to produce a list of the data in each of the columns without having to go in and delete out all the blanks myself? I.e. i want to reproduce the table but without any of the cells which do not have any data in.
In sort of a follow up to the Condensing A List Thread
[url]
I would like to condense the list into a series of list for each category.
The example below is a synoptic view with some data and does not include the full table.
I would like to do it with functions, i can do it with vb, at this point, I'm more on a mission to do it without it.
Windows 8, Excel 2010,
What is a condensed way of saying;
Dim x As Integer
Dim y As Integer
Dim z1 As Integer
Dim z2 As Integer
Dim z3 As Integer
Dim z4 As Integer
Dim AA As Integer
I have a pretty slick macro that once ran will save the spreadsheet and copy the input to a master sheet, so far it is very functional. I borrowed most of the code from within this forum, as VBA is not my strong point. My problem being that when the script runs and posts the output to the master sheet, it is pasting formulas. I need it to strictly paste the values in, otherwise my master sheet is referencing hundreds of other worksheets.
Sub Finished()
Dim iReply As Integer
Dim countColumn As Integer
Dim MyFullName As String
MyFullName = ThisWorkbook. Name
iReply = MsgBox(Prompt:="This will upload your tracker and exit, Are you sure?", _
Buttons:=vbYesNo, Title:="")
If iReply = vbYes Then
'If Yes Do This
Application.DisplayAlerts = False...................
I have some VBA that dumps various sheets data into an SQL Database.
Part of that requires me to sanitize all of the fields before they make it to the DB, (at least to prevent the code from breaking itself w/ errant ' characters.
right now my code is as follows
Code:
If InStr(aa, "'") > 0 Then
aa = Replace(aa, "'", "''")
End If
If InStr(bb, "'") > 0 Then
bb = Replace(bb, "'", "''")
[Code] ......
I was hoping to condense it to something like the following, however it is not working how I hoped / want it to. .. I had found somewhere out there that this Eval() function possibly could be used to 'reference' dynamic variables, however it does not appear to work at all anymore, and even then it may only have worked to 'read' and not 'write' to the variable. (Excel 2010, on Windows 7 64-bit).
Code:
itemsToSanitize = "aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv,ww,xx,yy,zz,aaa,bbb,ccc,ddd,eee,fff,ggg,hhh"
ITSArray = Split(itemsToSanitize, ",")
For Each thing In ITSArray
If InStr(Eval(thing), "'") > 0 Then
Eval(thing) = Replace(Eval(thing), "'", "''")
End If
Next thing
A1 would be the cell that users would enter quantities of 500, 1000, 1500, 2000 etc and based upon what they entered-cell a2 would give a corresponding entry of 10,20, 30 etc.
View 4 Replies View Relatedhow can i do the following equation?
40$ if the sum is less than 1000$
75$ if the sum is less than 1001$ tO 3000$
100$ if the sum is greater than 3001$
C16 X C19 if sum is greater than 12000$
all should go in one cell
How to stop my 100% from changing to 1000% after it pastes?
Here's the pc of code that is performing the copy/paste from one sheet to another sheet within the same workbook..
Code:
With Sheets("BOM Worksheet").Range("C" & nr)
.Value = c.Offset(, -16).Value
.Font.FontStyle = "Bold"
.Font.Color = RGB(186, 85, 211)
End With
I use a worksheet full of formulas to know what divisors a number have, but i need to see what numbers have no decimals in about 500-1000 cells. Is there a formula whitch computer can use to see if it shows a number or not (if a number have or dont have decimals)?
View 2 Replies View RelatedI have about 300 cells filled with different formula's like the ones written below.
=SUMPRODUCT(--('Book 1'!$B$1:$B$1000="H"),--('Book 1'!$C$1:$C$1000=D21),('Book 1'!$W$1:$W$1000))
=SUMPRODUCT(--('Book 1'!$B$1:$B$1000="H"),--('Book 1'!$D$1:$D$1000=I21),('Book 1'!$S$1:$S$1000))
Spreadsheet works great, but I've realized that I should have expanded beyond the 1st 1000 cells (example: $1000). One book 1, my data entry will extend beyond row 1000.
Is there a way I can replace all $1000's on the spreadsheet with say $3000 without having to correct each of the 300 cells separately?
i have a figure of 1000 in cell a1. i want to divide it by a figure in cell b1 and have an answer in c1, or divide it by a figure in c1 and have an answer in b1.
in summary, cell a1 has i figure in it while cells b1 and c1 are empty until i enter a number into one or the other.
I am having a problem with vlookup. I have the formula working but would like to divide it by 1000 then multipy by 24. When I enter /1000*24 after the colon in the vlookup formula my answer is 0(zero). If I don't try to divide and multiply the answer is correct.
View 9 Replies View RelatedI made a thread similar to this earlier but was unable to get to a desired end result.
I am trying to make a formula that will count the number of cells that do NOT have a fill color AND have a value over 1000 AND are greater than 60 days old as of the last day of the previous month.
Attached is a file with sample data so you can better understand
I included 2 formulas in the file that I am already using. Just in case that information is needed/relevant.
about making my code a bit more useful.
I started with a basic code as below which basically looks at upto 1000 part ids in column A and goes to my database to find corresponding Product Codes from a table in the database call PART
How would I modify the below code to extract all of this data from multiple files? I have about a 1000 files that I need to extract all of the data from to manipulate in Excel.
Code:
Sub ImportWordTable()
Dim wdDoc As Object
Dim wdFileName As Variant
Dim TableNo As Integer 'table number in WordDim iRow As Long '
[Code] ...........
im trying to create a simple random sample from my data set of size n=100 and then i need to repeat that step a 1000 times to make a new data set that i can transfer over to stata. Everything I have seen on the internet involves generating random numbers which isnt what i want. I need to be able to generate a random sample.
Currently my excel spreadsheet consists of 4 columns with 200 entries in each column.
I've been trying to put together a VBA code that allows me to find a number between 1000 - 10,000. I am able to find any number below 999 but can seem to find anything above 1000. I've been using the following ....
View 13 Replies View RelatedI have a rand () which provides me a different number upon calculate. I would like to run a loop for 1000 times and take the value and copy and paste in a range.
The below sorta works, but at times it stops or doesn't work at all. I have a loop for the counter and the for each to place the value into the cell and have it run over and over and placing the value in the next cell underneath. I have the counter at 10 so I dont get stuck in some endless loop before I know it works.
Code:
Sub montecarlos()
Dim MCs As Long
Dim c As Range
Dim lCount As Long
Dim lNum As Long
lCount = 0
lNum = 1
Worksheets("MonteCarlo").Activate
[code].....
HOw do we hard code excel to show when number typed as with the 1000 separator.
For Eg: 1,000
How can i format a column of cells so that if a number is less than 10 for eg that that particular cell is then multiplied by 1000.
View 9 Replies View RelatedI'm trying to accomplish is to take an Excel file that contains one column of data consisting of up the maximum number of rows of data (numbers formatted as text? "000000000") and export the data to a text (.txt) file 1000 rows at a time. I would also like the code to allow me to name the .txt files in succession, for example, Pg01, Pg02, Pg03, etc.
The files are going to be used to query a system that will only accept text input 1000 items at a time.
I run the following code to ensure the data is formatted consistently:
Sub a_VerifyDataForInput()
' Start at Cell A1
Range("A1").Select
' Select Column A
Columns("A:A").Select
' Format data in Column A
Selection.NumberFormat = "000000000"
' Replace all "|" (whatever you call this thing ... pipe???)
Selection.Replace What:="|", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
' Replace all "-" (dashes)
Selection.Replace What:="-", Replacement:="", LookAt:=xlPart, _ ........................
Is there any way witch i can use to make the auto-filter range bigger than 1000 cells?
View 2 Replies View RelatedNeed macro to search approx 1000+ xls files in folder/directory for common text string "see reference" and then output the file number which is located in cell A1 to new spreadsheet for each file the text "see reference" is found.
View 2 Replies View RelatedI need a formula that returns the Nth number from a single column that contains a small number of values within a span of 1000 cells. E.g., within 1000 cells there are 36 with numbers and the remaining cells are blank. I need to obtain the first occurrence of a number in the column, then the second, third... to the thirty-sixth. The end result would be a column with 36 numbers with no blanks in between without loosing the correct order of the numbers.
I have excel 2003 and have been tooling around with the index and lookup functions with no success.
I had sent 1000 emails to the my customers by using mail merge in word document. Now I need to reply to these 1000 customer again individual one by one. The message is the same, but I need these thing to be sent in individual.
View 1 Replies View Related