Find Company Stock Information Based On Date & Symbol Input

Mar 9, 2008

What I have is an output of about 30 worksheets of individual stock data in a workbook, all with the same column headings, laid out like the following (so that the Column Headings are stock data as recorded on the Date in Column A):
<Stock Name>
<Date> <Price> <Price to Book> <etc.>
with the stock titles also as the names of the worksheet.

What I want to do is create a macro that outputs to a single worksheet where I can input the stock name and a certain date for the stock, and then have it insert the appropriate row from the stock's worksheet underneath.

So, if I say I want the data for Stock A on March 24, 2007, I can input those two and have it output the appropriate rows from the worksheet.
Or, more generally, I can create a list of stock names and dates, and have the macro output that data underneath.

View 3 Replies


ADVERTISEMENT

Macro To Find And Add ISIN For A Company Based On Stock Codes

Jul 20, 2014

I have trying for 2 days now to write a macro/VBA that looks up IF the stock codes (i.e., in column A and G) match THEN insert the ID_ISIN from column H in the empty ISIN column C.

or should i use Vlookup?

View 3 Replies View Related

Matching Stock Portfolios With Differing Company Names

Jan 8, 2012

I'm trying to match stock portfolios of mutual funds with stock indexes to find out how much the portfolios deviates from the indexes (active share).

The deviation is simply calculated as the percentage of the portfolio holdings not included in the index.

The data I have is 10 years of monthly portfolio weightings for 30 mutual funds and 8 indexes, organized with company names in column A and the percentage weight for each company in each month in the adjacent rows (see simplified screenshot). I want to match all companies with all indexes.

Twofold:

1)The mutual fund data comes from one source and index data from another. This means company names are not spelled exactly the same.
2)Within the mutual fund datasets, a company might be listed more than once with different names. The different names refer to different periods in time, so what should be matched with the index is the sum of these columns.

The specific task that I need to accomplish is to match company name in the portfolio with the index and then return the absolute difference between weight in the portfolio and the weight in the index for each month. (see screenshot).

Hence the result I'm looking for is a matrix of company names (of each portfolio) in col A and the absolute difference between the portfolio and the index weight in the adjacent row.

The best solution I've come up with is to device a list of all the portfolio company names, including "doubles", and then for each index, add these company names and copy the row weightings. This I'm not particularly happy with because index weightings would no longer sum to 100 and it would be difficult to check for errors. Also, it would still take a lot of time.

View 6 Replies View Related

Input Symbol Without Altering Content Of Cell?

Dec 28, 2012

I have a column ful with numbers and would like to add an h (hour) after every number. I found that it is possible for valuta (dollar sign). Is there a way for random symbols that are not in the valuta list?

View 3 Replies View Related

Userform Data (allows Input Of Information And Then Deposits The Information On A Specific Sheet)

Feb 11, 2010

I have created a userform that allows input of information and then deposits the information on a specific sheet. I am looking for a way to have that information not only deposited on the specific sheet it is already set to but also to another sheet based on a selection made from a combo box.

here is my current

View 5 Replies View Related

Loop Macro Which Downloads Historical Stock Information?

Feb 21, 2012

How to loop a macro which downloads historical stock information into Excel. I had the macro working for a single sheet, but I want it to update all of the sheets in the work book except a few. Now I keep getting a Error # 1004 unable to open error on line .Refresh BackgroundQuery:=False

Code:

Sub GetData()
Dim ws As Worksheet
For Each ws In ActiveWorkbook.Worksheets
' Exclude certain sheets
If ws.Name "Porfolio" Or ws.Name "Benchmark" Then

[Code]....

QueryQuote:

With ActiveSheet.QueryTables.Add(Connection:="URL;" & qurl, Destination:=DataSheet.Range("A5"))
.BackgroundQuery = True
.TablesOnlyFromHTML = False
.Refresh BackgroundQuery:=False
.SaveData = True
End With

[Code]....

View 1 Replies View Related

Fill Date Across Columns Based On User Date Range Input?

Mar 5, 2014

based on user date ranges entered on sheet1, I'm trying to write code that will write each month of the date range on other sheets across the 2nd row. at this point I'm getting "object required" error at "Set DateStart = Cells(2, 6)"

I also want the date format to be mmm-yy (Mar 14) on the sheets even if sheet1 has a different format. I tried using sourcerange instead of DateStart, but that didnt work either.

Code:

Dim projStartDate As Date
Dim projEndDate As Date
Dim DateStart As Date[code]....

View 1 Replies View Related

Find Next Date In Range From Input

Apr 6, 2008

have a range of dates in a column i can match an input date with this code where the input date is in cell H20 (eg 04/04/2008)

With ActiveSheet
Range("D:D").Select
Range("D:D"). Find(What:=Range("H20"), After:=ActiveCell, LookIn:=xlValues, LookAt:= _
xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:=False _
, SearchFormat:=False).Activate

End With

the problem is that not all the dates in the range are consecutive and there may be the same date more than once eg
01/04/2008
03/04/2008
03/04/2008
05/04/2008

the problem is if the date in cell H20 (inputted by user) does not exist in column D, it all goes wrong.

what i would like to achieve is a way of incrementing the cell date by one day until it matches a date in the range, in this case if 02/04/2008 was entered 03/04/2008 would be picked up.

View 3 Replies View Related

Formula To Show Row Information Based On Date?

Mar 12, 2012

I have a Sheet1 that contains 900 rows of information 14 columns wide (C7:P7 are headers). Column M has an important date. The information is constantly changing.

On Sheet2, I want to display the upcoming dates, in numerical order for each row that's within 5 days of today's date. After the date has passed, it no longer needs to display on Sheet2.

View 1 Replies View Related

Find Value In Array Based On Partial Input From User

Feb 22, 2013

I am trying to find a value in an array based on partial input from a user.

The user will enter the last four digits of a number.

Then the formula should find the number in a list and return that complete number

I will explain using example.

Here is the list of numbers (array):

3003280197
3003283233
3003625456

User input= 3233

formula output = 3003283233

View 3 Replies View Related

Transfer Cell Information To Another Sheet Based On Date?

Dec 5, 2013

I have a worksheet, with a "cost" column, and a date column. I have another sheet with dates pre-written, and a cost column as well. I'd like to know how to make the cost from worksheet 1 go to worksheet 2 under cost, but also add up any costs that are on the same date.

View 9 Replies View Related

Find/replace Using Symbol For End Of Cell?

Nov 7, 2009

Is there a way to define the end of a cell in a find/replace? I.e. I want to find characters like this:

;;[space character][end of cell]

and replace with

[end of cell]

(that is just delete the ;;[space character] bit when it is followed by end of cell)

View 5 Replies View Related

Excel 2010 :: Find Out Permissions On Set Of Folders On Company Network?

Apr 30, 2014

I have been tasked with trying to find out the permissions on a set of folders on a company network. I know write vba code to manipulate a excel spreadsheet without any problems, but it is when i'm using objects that it starts to go beyond my capability. whilst searching i found this code:

Code:
Sub test1()
Const ForReading = 1, ForWriting = 2, ForAppending = 8
Const FullAccessMask = 2032127, ModifyAccessMask = 1245631, WriteAccessMask = 118009
Const ROAccessMask = 1179817

[code].....

It does a perfect job but puts the data into an html file. i managed to get it to input the data into the spreadsheet as well but i would like to clean this code up so that it is not producing another file (namely the text file or the html file) and just put the results into the excel file I have entered the module into.

I did start to remove the references to any file name, but that is where i run into trouble and it wouldn't run any more due to object not found.

I'm on Win 7 using Office 2010

View 1 Replies View Related

Moving Rows Based On Input Of Date?

Jun 17, 2014

I am a production manager for a homebuilder and I am trying to create an Excel spreadsheet that will allow me to input a date in a column and have a second column dependant on the date and move as I change the date.

Since no work is done on weekends, I'd like the output column to skip weekends and move the input to the next available weekday. I have conditionally formatted the date to be a red fill as a visual cue but I'm not sure where to go from here.

View 7 Replies View Related

Sum Year To Date Based On Most Recent Input

Oct 7, 2006

My spreadsheet uses alternating columns for actual and budget inputs
I would like to preload the budget for the whole year
But the ytd formula should only show results to match the input of actuals

In otherwords, If I input actuals for period 1, the YTD formulas for actuals and budget should return YTD period 1 only and ignore the remainder of the budget inputs

After period 2 actual inputs, the formulas shlould update to reflect period 2 YTD and so on and so forth

How can I accomplich this?
Sample of layout attached
Totals at Cols AK-AM

View 3 Replies View Related

VBA Code To Find Row Number Based On Data Via Input Box And Highlight Cell?

Jun 21, 2014

I want to enter a unique ID into an input box which will tell which row that id is available and then it will again ask me which column the cell needs to be highlighted. Once i enter the data, it will then ask me what is the change in data (again via input box). i can then enter the change data and then it stops.

View 1 Replies View Related

Sorting By Company And Date In Pivot Table

Feb 1, 2008

I have attache a file to use as a reference, the real file is over 10 000 rows long.
What I need is to be able to quickly make a summary of each company within a certain period (let's say monthly) and be able to calculate the sub total of the GST column. Every report that's created than needs to be saved and put into a seperate file e.g 'TFQ Sep 07'. I understand I need to use a Pivot Table but can some one just give me quick example of how I would do this?

View 2 Replies View Related

If And And: If Company A (A1) And Company B (B1) Both Have Indices Greater Than 125

Jun 1, 2006

I have a nested if formula that isn't working and I know there is a real simple fix.
Here is the situation: If Company A (A1) and Company B (B1) both have indices greater than 125, I want that to show that in my recommendation. For example: I used if(A1>125&B1>125,"Company A and Company B",if(A1>125,"Company A", if(B1>125,"Company B","None"))). For whatever reason, the first nested if statement isn't working correctly. what I am doing wrong with this if/and statement?

View 3 Replies View Related

VBA To Hide Columns Based On Input Date Range?

Mar 26, 2014

I need some VBA code to hide columns if they are outside of a specified date range.

- the worksheet i need to run this VBA on is named 'Summary'
- Columns A to G need to remain un-hidden at all times
- from H17 to ZZ17 i have every month of the relevant years listed (all there chronologically)
- D3 holds the 'Date From' variable
- D4 holds the 'Date To' variable

View 11 Replies View Related

Merge Two Sheets Based On Company Name?

Apr 2, 2012

I have two sheets that both have all the same company names on them but one of the sheets doesn't have ALL of the company names. So, one sheet might have 2500 rows with company names and data specific to that sheet, and the next sheet might have 2450 company names (all match up to the first sheet, but 50 are missing), with different data.

The first sheet is A through L, the second is A through K.

Attached is a sample spreadsheet expressing

First sheet:

A:[Name]
B:[DBA]
C:[Owner/Officer_1]
D:[Owner/Officer_2]
E:[Owner/Officer_3]
F:[Owner/Officer_4]
G:[Phone]
H:[TxDMV]

[code]....

Company Name and Name will match EXACTLY on each sheet, but the second sheet won't have quite as many. So, if possible, I would like to, where column A in matches in both sheet 1 and 2, move or copy all the data from sheet two into the columns on sheet one that come after L.

View 2 Replies View Related

Excel 2007 :: Sum Cells Based On Date Range Input

May 28, 2014

I am using Excel 2007.

Sheet 1 - I have columns filled with dates (weekdays only) For example 28-May, 29-May, 30-May up to 28-Nov. Above 10 rows below each date columns and each cell has some values.

28-May29-May30-May
0.50.50.5
1.01.01.0
1.01.01.0
1.01.01.0
1.01.01.0
1.01.01.0
1.01.01.0

Sheet 2 - I have Start date defined in B1 Cell, and End date defined in B2 Cell

I need defining the formula to sum all the cell values fall between the date range defined in Sheet 2 B1 and B2.

For Example if B1=28-May B2=30-May, I want the sum of all the numbers come under the range of 28-May to 30-May, with this above example, it should be 19.5.

View 9 Replies View Related

Cell Update With Real Time Stock Quotes For Particular Stock

Aug 7, 2012

What is the easiest way to have a cell update with real time stock quotes for a particular stock?

View 4 Replies View Related

Double Lookup Function: Find Total Invoices Billed In February For ABC Consulting Company

Apr 7, 2009

I have a spreadsheet in which I am trying to track invoices billed according to month in question. For example, I need to find total invoices billed in February for ABC Consulting Company. I have a database in the same spreadsheet that contains all invoices billed for an entire year for all companies. How do I pull invoices for a particular month only, in this case for the month of February? I have attached an example of spreadsheet in question. Included is a tab which indicates desired results.

View 5 Replies View Related

Stock Order Sheet To Be Created From Stock Inventory

Jan 8, 2014

I have created a stock sheet on Sheet1, i have say 100 items and each item has a min and max stock order. Once the item hits a min low, the last cell (O) will display an order needs to be placed.

I was wondering if there way a way that on sheet2, it can calculate all the data on sheet1 and if there is stock that needs to be ordered, it will appear on sheet2?

This way i can just print sheet2 and send it to the supplier without having the entire 100 items displayed -if it does not need to be ordered?

View 7 Replies View Related

Input Date In A Cell Will Show Month And Year Based In Database From MS Access

Jun 1, 2014

I have my ms access and ms excel which is connected each other .

=> now in my ms access have a table name (tblMonth) has columns (year,MonthNum,StartDate,EndDate)
HERE: sample in january(1) and feb(2)

YearMonthNum StartDate EndDate
2014 130/12/201305/01/2014
2014 106/01/201412/01/2014
2014 1 13/01/201419/01/2014
2014 120/01/201426/01/2014
2014 127/01/201402/02/2014
2014 203/02/201409/02/2014
2014 2 10/02/2014 16/02/2014
2014 217/02/201423/02/2014
2014 224/02/201402/03/2014

=> and for my ms excel has its columns (year,month,date) in this if i input the date that is base in the database range from StartDate TO its EndDate will automatically put the month and year which base also in my database (year,MonthNum)

HERE:

A1 B1 C1
Year Month Date
A2=2014 B2=January C2=01/01/2014

View 3 Replies View Related

Find Corresponding Date Range Based On Single Date And ID Number

Mar 28, 2014

I'm trying to combine the hours that a employee worked on a single date, with one of multiple time periods that exist for that employee.

I have two sets of data.
Set 1 (hours)
Employee number, date, hours
12345, 1-2-2014, 6
12345, 1-3-2014, 8
12345, 1-10-2014, 8

Set 2 (periods)
Employee number, start date, end date
12345, 1-1-2014, 4-1-2014
12345, 6-1-2014, 1-2-2014

What I'd like to do is to add the start and end date of Set 2 to Set 1 for every row in Set 1

In above example the result should be like this.
12345, 1-2-2014, 6, 1-1-2014, 4-1-2014
12345, 1-2-2014, 8, 1-1-2014, 4-1-2014
12345, 1-10-2014, 8, 6-1-2014, 1-2-2014

View 13 Replies View Related

Indent Data Based On Adjacent Symbol

Sep 21, 2007

I am trying to do some automatic formating of a list of data. I can accomplish 90% of what I would like to do via a simple keystroke record macro. What I cannot do is shift the contents of Column B based on the contents of Column A. Column B will have to be shifted to the right 1, 2, 3 . . . cells. Below is an example. Column A symbols as it relates to number of cells to shift Column B

Symbol......Amount of shift
-[-]..........0
--( ).........1
--[-].........1
---( )........2
---[-]........2
----( ).......3

I have included a sample .xls showing the Original Data and the Desired Output

View 5 Replies View Related

Capture Date Of Highest Value Of Stock Portfolio?

Apr 23, 2013

I am trying to capture the date at which my portfolio was at it's highest. I enter the value of my portfolio in H35. F36 is where I am trying to capture the date at which my portfolio was the highest. If a previous date was higher, leave as is.

This presents a problem of a circular reference, but do not know a way around this.

I have the following formula in F36
=IF(H35>G36,(F37),(F36))

In F37 is todays date

G36
=IF(G36<=H35,(H35),(G36))

H35 is value of my portfolio today

View 4 Replies View Related

Formula: Split A Text String Based On A Symbol

Oct 13, 2009

is there a function that will split a text string based on a symbol. I know how tyo use left and right, which are based on a set number of characters but I want to split based on a "/" mark. whats to the left of the "/" mark and whats to the right of the "/" mark. any ideas. an exaplme is: tom / tim. i want a formula that will put the word "tom" in a cell and another formula that will put "tim" in another cell.

View 9 Replies View Related

Creating Catch All Booking Form And Contract System Service Based Company

Feb 19, 2014

I've been tasked with creating an updated booking system for a company which offers projects / services to the educational sector (UK Primary Schools.) I've done an alright job at augmenting their current Excel based system, but I would like to take it further so that the system is more all encompassing.

Currently, the booking form is filled in when a booking is made and the data from that is populated into their copy of the contract and our copy of the contract using simple "=" and to a certain extent, the text on the contracts is manipulated based on the booking form data using "IF" functions.

There is a basic macro which removes excess lines from the contracts if they aren't used, but that's about it. The difficulty we're having with the current system is that a lot of our projects are bespoke, happen over more than one date, and require a lot of manual manipulation in order to get them ready, which sort of defeats the object of having a 'clever' booking system.

I don't know very much about VB, but the sort of thing I would be looking to integrate is having drop down lists to select a 'project' which would load project-specific text into the contracts area. Also, instead of having to remove lines manually, I would like the data to be 'dropped in' creating rows as appropriate.

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved