VBA Code Or Formula To Convert Format Of Extracted Data
Apr 3, 2014
I have VBA code the extracts data from a source and puts it into excel. I need to change the format of some of the extracted data so i can use it for a VLookup formula. Reference the attached example. Columns A AND B have the extraced data which are dates. In Columns C and D or E and F I have typed what I would like the data to look like so I can use in a Vloolup formula. Is there VBA or a formula that word change the format of the dates in Columns A and B to look like C and D or E and F. The changed format could be moved to any new cells or rows.
simplifying a formula which gathers data from about 50 worksheets from within the same work book.
The data to be gathered is in the same cell on each worksheet and is simply a number but i want the SUM of theses numbers carried forward to another worksheet. Each worksheet is named by date i.e. sheet 1 is named "16 June 2014" and sheet 2 is named "23 June 2014" and so on until "30 March 2015" (Each sheet represents one full week Monday - Sunday).
I received assistance from NBVC for combining data from two cells. Post http://www.excelforum.com/showthread.php?p=2135144. I need to convert the formula into macro code. I thought I would be able to convert it on my own, but running into some troubles with run time errors. Here is the Excel formula, which is working fine.
NOTES BC37Size 3/8 x 3/4 x 3/8 40ft4038Size 3/8 x 7/8 x 3/8 20ft2039 40total041 42Size 3/8 x 1 3/8 x 3/8 20ft 43 Spreadsheet FormulasCellFormulaC37=MID(B37,22,2)C38=MID(B38,22,2)C40=SUM(C37:C38) Excel tables to the web >> Excel Jeanie HTML 4
Problem 1. With the above I have managed to extract what I need into column C. The formula in C40 does not produce the desired result of 60. C37:C38 is formated as Number.
Column B is populated from a drop down box where the list was populated from a text file converted to Excel.
With that said, Problem 2 If the string that is currently sitting in B42 should end up in in B37 as a choice from the drop down, the formula I have in col C would not produce what I need.
I'm sure what I have in C is not the right approach. And I don't understand why the SUM formula will not work.
See the attached file. In the RawData tab, I have the Type, The Date, and total for that date and type. Using a macro, i would like to redesign the output(onto another sheet) so it can be updated to a database table(i already have the code to export to database). The output should look like what is in the "OutputExample" tab. Figures in the OutputExample tab are only for the first three dates. So currently, I have the output as:
Employee Name First line of address (Contain alpha numeric no) Second line of address (Contain state and Pin code) Phone no Fax no Email ID Wed site address First detail field (Contain alpha numeric no) Second detail field
There is some 4000 Line item in this
Can this line item be arranged in the in Different Column form Column A-I
I'm trying to convert the attached data into having 1 row per record to enable the creation of a database or a pivot table. I have 1300 records and don't know how to do it systemically. The top set is each of the field names, and below it are 3 example records.
I have a sheet with data 7 columns wide and up to 1500 rows long. Below are a few lines from the sheet. The data from the sheet is grouped into "months" as shown in the header down the first column, "Show June, 2013..." and "Show July, 2013...", and so on. Is there a way I can make Excel re-align the data into ONE long row of data for each month? Each new month row must be "triggered" by the text (like the word "Show") because the actual cell number of where the new month begins may change with new updates. I want to do this because I plan to refresh the data once at the end of each day from the web and apply the new data to the "next" row of data. So eventually, I can have a history of "Last" values I can chart for each "strike" for each month.
I use a software to find relationship between some variables. this software can export results (excel mathematical formula) to a text or excel file. I need use this formulas in my VBA codes. but I should convert about 100-150 formula each time, hence this is very time consuming and hard to do that manually. I wondering if there is any macro code or third party software for that?
I am about to take on a rather large excel project for our company. The first part is coming up with how to deal with our drafting department's length inputs. In this project, our users will be entering lengths in a unique format. I have to convert that unique format to a standard Foot-Inch-Fraction format.
To try to keep the file size down and keep the complexity down, converting a cell formula to VBA so i can run this on a group of cells rather than repeating my code downward multiple rows on multiple sheets.
It is either this or come up with my own font that will convert it for me but I do not know where to start with that. How to take a stab at converting this to a VB code i can run?
A3 = 1.0108 B3 = 1'-1 1/2"
The code in B3 looks like this:
[Code] .......
An explanation of the unique format we use in our drafting department:
Basic Feet, Inch and Fraction format = 0 . 00 00 = Feet . Inch Fraction
The numbers left of the decimal point are feet. The first two numbers to the right of the decimal point are inches and the next two are sixteenths of an inch.
I have several large excel spreadsheets with thousands of entries (autocad drawing numbers). In one column it lists the date the drawing was created. Unfortunatley most of the entries were input as text. Even though I have formated the column to a date format (01/01/2009) most entries are not converting. Below is an example of some of the cells:
I have a excel spreadsheet that has employee names, email address and DOB. The DOB format is 23/03. I need a program that will lookup the DOB row and when it matches the value I enter it extracts the employee name and email address. Once it has this information I need it to copy into an already created email template and send its off. On some days there are more than 1 person with a birthday so it will need to send multiple emails.
I have 2 Workbooks. One is invoice data extracted from SAP and the other is a workbook I have to send to the client (has about 10 worksheets containing 5-10 different branches in each worksheet). The layout of the one I send to the client can not change so I am trying to import the values form the 1st workbook (SAP) into the 2nd workbook. What I do now is copy the first 4 columns of data for each branch and paste it into the 2nd workbook.
I was playing with a VLookup formula but I don’t think that is the correct formula. I need the second workbook to be populated with all the invoice info (Number, Type, Date, Balance) that appears in the raw data workbook.
=VLOOKUP(H14,'[abcbank raw data sample.xls]Sheet1'!$A:$A+'[abcbank raw data sample.xls]Sheet1'!$A:$E,4)
H14 is the branch number on the client sheet (I cut the column containing the branch # on the raw data and inserted it before column A).
I have two workbooks. One is called the Extraction Sample, which is attached, and the second is the Sorted Results workbook.
The Extraction Sample workbook contains a master sheet with data in a chart, which gets updated periodically. The Sorted Results workbook contains a list of specific extracted results from the Extraction Sample workbook.
The formula I am trying to create for the Sorted Results workbook needs to do two things:
1. Extract only the rows from the master sheet in the Extraction Sample workbook which contain the word 'Thing' in column D.
2. List the extracted rows on the Sorted Results workbook in numerical order using the data from Column B.
I have a consolidation workbook and source files.I would like to convert the data from the source files into a list format in the consolidation workbook.
I have attached a sample of the sheet format of the source files in the attached file, called 'Page 5'. The other 2 sheets are 'Template' and 'Instructions'. The 'Template' sheet is what I imagined would be the list format of the data copied from the 'Page 5' sheet. Instructions is where the lookup table for currency is.
So basically starting from row 8 in 'Template' sheet, I would like to copy and paste from 'Page 5' sheet to 'Template' sheet: - H2 to A8 & B8 - B2 to C8 - According to the list of currency in 'Instructions' sheet, lookup the currency according to operating unit in C8 and paste to D8 - D5-I5 to E8 - row A8-A23 to column F-N
I actually have had a similar problem before, which Derk has helped me here - link: Use Access or XL? (I've decided to start a new thread because this is a more relevant forum).
I have tried to modify the code but I am rather lost as to which part I am supposed to modify.. Note that in this code, the source data is in separate file instead.
Sub add()
Dim wb As Workbook, f As Worksheet, t As Worksheet, j As Integer, k As Integer, n As Integer Dim mty As String, yr As Integer, d As Date, bu As String, cur As String, sTodo As Variant
sTodo = Array("Page 5") 'finish adding the names Application. ScreenUpdating = False Set t = Workbooks("Example1.xls").Worksheets("Template") i = t.Cells(65536, 2).End(xlUp).Row
I have a workbook that contains something like 50 worksheets and they all contain data with the same columns, for example column A is Project, column B is Project Name, etc. I need to convert data in each worksheet into an Excel Table. There has to be an easier way than manually converting each worksheet into a Table. However, when I group all of the sheets, the option to Insert a Table is not available even though the data starts in the same row and contains the same number of active columns in each worksheet. Is there an easier waty to insert a table in all of the worksheet simultaneously?
I have an organizational hierarchy dump in excel from an SAP ERP system. The format of that file is less than user friendly and I need to convert it to a flat file format so I can do pivots against it or possibly dump it into access database. The background is as follows (I am also attaching a file).
The organizational structure is multinoded/layered. Top most node is a company second from the top are divisions designated by 02DivName each 02DivName has multiple nodes assigned to it. The lowest level of the hierarchy is a department, always a numeric, always same length.
That's where it gets interesting. Each node/layer under 02DivName has a technical description and text description they get broken up into two different columns when SAP dumps them. Technical descriptions can be used to identify where in hierarchy the node falls(parent/child). For example 02A is a child of 02DivName 02B is a child of 02A 02C is a child of 02B and of course all of them roll up to 02DivName. There could be multiple 02A's under Div Name and their respective 02B's, C's D's would roll under them. So on export file it would be graphically represented 02A1 blank blank blank blank in that column and then change to 02A2 their respective 02B's would be in different columns works the same for C's and D's.
Here is another wrinkle the department is not always assigned to the lowest level grouping. I could have 02DivName dept, dept, dept, and then 02A group assigned to 02DivName. The department numbers end up on export file in the same column as fre form text descriptions for the nodes. It is staggered format.
The object of what I'm trying to do is basically convert the gibberish described above into flat file format via a vba script. I need to have node1 node1 desc node2, node2 desc, etc etc in columns the last column being a department number. So if for example I have a dept assigned directly to 02DivName directly all the other node descriptions will be blank if it's node 02A then the node1 and node2 will be populated. Any help will be appreciated. And here is the file with excel spreadsheet
I need to split in Excel some thousands of data rows containing text and numbers information of different character length Data to be extracted ( parsed) is stored in a single column( the first one) and needed results look like this:
Data to be extracted Needed results Address Name,Surname Phone no. Green Street no 16 Smart town Schmit Anders +3900098787867
[Code] .......
Data is composed by addresses, name of persons and phone numbers. Person's name is has two or three parts, address and phone numbers length is different ( 9 to 12 characters) I need to complete this difficult task (for me, obviously, ) in Excel using a combination of functions and/or multiple operations.
I am trying to develop a code which extracts the data from text files inside a folder (Folder test in my desktop) into one sheet. The Macro is in the workbook “Text Extract” which is an excel 2007 file. The data of each text should be copied to Sheet1 of this workbook one below the other. For testing purpose I have kept only one text file in the folder and was trying to copy the data from the text data extracted sheet to Cell A1 of Sheet1 of workbook “Text Extract”. The code works fine till copying the data, but shows below error in the line “Selection.Paste”:
Run time error 438: Object doesn’t support this property or method.
Below is the code: Sub LoopThroughFiles() Dim strFile As String Dim strPath As String
I want to track daily sales of a shop with the tenders (Cash, Master, Visa)seperated.
Everyday there will be a file ctp.dbf from a folder YYYYMMDD (previous day date) which contains sales details.
I tried to use sumif commands and everything is working fine. everytime i have to open book.xls and from it I do a files>Open to open the ctp.dbf for the calculation to be done. is there a way where by i can open 1 file and everthing i calculated properly?
Also this book.xls can only do for 1 day how can i go about having the daily sales detail of the month (look something like sales summary.xls) or even year in 1 excel file?
attached is book.xls and sales summary.xls for reference.
I have a column of cells with values - 0.2%, 0.32%, 0.22, 0.5 etc. The cells with % symbol are in ' Percentage, 2 decimal' format while the plain numbers are in 'General' format i.e. column contains cells in either of these formats. I need a macro where I can specify the column and it will select the cells with the % format, convert it to 'General' and multiply the result by 100 eg. 0.2% converted to 'General' becomes 0.002. When multiplied by 100, result is 0.2 i.e. is displayed without the % symbol.