Scenario manager: can you create scenarios in a table, and get the Scenario Manager to read from there? - excel

Microsoft's official site has an explanation on how to use scenarios in Excel.
If you name the input cells, the scenario manager will show the name, so it's easier to remember that $C$5 is, say, the price.
My question is: is it possible to set up the scenarios in a table somewhere in Excel, and get the scenario manager to read from there? Setting multiple scenarios in the scenario manager is very fiddly, time-consuming and error-prone, especially when the inputs are linked - e.g. setting 10 scenarios where each scenario is an x% change from the previous.
Any suggestions?
PS I know all these things can be done very easily in a scripting language like Python or R, but in this very specific case the calculations are not too complex and the file needs to be shared with other people, so I must use Excel.
VBA would be a last resort because some of these people have VBA disabled by default.
Edit
To clarify, what I'd need is a way to create a table like this below, where those in blue are the inputs, and those in grey are the outputs. I have put together a banal example below, along the lines of the example in the VBA macro answer given below, but the general idea is:
define a number of scenario as the combination of multiple inputs (more than 2) ;
create a table showing, for each scenario, the inputs and some key outputs;
note the table doesn't have all the possible combinations of all the inputs, like the macro given in one of the examples - that would be too much and wouldn't be very readable.
I could put together a quick VBA script that changes the inputs in the model, reads the result and creates the table, but I was wondering if there is a better way - VBA is typically not very robust, in the sense that just changing the location of one cell can often mess things up. I usually avoid Excel for the more complex models (this would be banal in any scripting language), but this I have to do in Excel.
EDIT #2:
Trying to further clarify what I have in mind, I have put together the screenshot below. Each output is the result of many different calculations, and CANNOT be calculated as a small, simple formula - if it could, I would not have any issue, of course!
My issue is that:
- if I change an input, then all the many many calculations occurring behind the scenes change
- the outputs are read from all those calculations
- I cannot use two-way what-if tables
If even this is not clear, the only other thing I can try is to upload an Excel file, which is generally discouraged on SO.

Scenario Manager is a built in function with it's own GUI.
For this reason, the function will be limited in what it can call (only data entered in the GUI)
VBA will allow you to manipulate this data, telling it where to pull the changing values and what data to change it by
So the answer for your specific query:
Can I use Excel without VBA to perform Scenario Manager tasks not set by the GUI?
No.
But it doesn't mean fiddling with the Manger itself would be horrendous. There are ways to teach and learn with it, but also if you save a macro enabled document, users should be able to turn the macro on with the click of a button - so VBA can be an option too
I hope this helps?

Related

PowerPoint live fields, linked to Excel data

I would have thought this one would be asked to death so cannot see a solution - looking for a way to live link PowerPoint to Excel data, only for a word within an otherwise manually typed sentence.
I am not asking how to live link a chart or a table, I am asking how to have a live field within otherwise static text.
E.g. In a text box, there's the sentence "Revenue increased by 10% over the period, an improvement from the 7% increase over the prior period" and have only the '10%' and the '7%' be linked to two Excel cells.
I have seen that this is possible in the following pieces of software:
https://www.youtube.com/watch?v=mUGqgsT4gHU (skip to 20sec)
https://www.presentationpoint.com/blog/dynamic-text-boxes-powerpoint/
Doesn't seem like it's do-able in VBA though I'm comfortable in .NET too and have not been able to work out how this works, so any suggestion in either most welcome.
There are multiple suggestions to the effect of copy a cell and then paste-special - this does not allow you to embed the number in the sentence, it only allows you to past the cell in, which you would then have to type around. In the two links above, it is properly embedded and this is the type of solution I am after.
I think this is very do-able in VBA. The program on the website is of course very sophisticated, but you could very easily replicate some of the functionality.
For example by using tokens. You could enter something like "Best beer in city: #beerBrand#". Then you would iterate through your columngs and just search and replace the tokens.
If I get the program functionality right, what they do is ask the user to enter a prefix and sufix for each variable. That makes it even easier because you have the three parts of the sentence separate and you can just alsways replace the variable in the middle.
Would one of the approaches work in your case?

developing a front end app using excel spread sheets

We get at least 20 queries a day on an average from our clients, where in we have to open and look at data on 4 to 5 Excel sheets to answer them. questions such as what is my available balance, am i eligible for this etc. All our clients are connected to our intranet and have access to internet. I was wondering is there a way where we can develop a front end app (do not have budget for MS VB or any other) either in excel or any other to connect these 4 to 5 excel sheets to retrieve the data in response to queries (e.g. using perhaps some if and true/false queries). I am not an advanced Excel user but would be great for an advice from tech experts.
Yes, i wouldn't call it an app but consider a worksheet like a dashboard. You can have a cell for entering client name, and then use formulas to look up relevant information of the name entered. The cosmetic and arrangement of the information retrieved and published on the dashboard is up to you and of course do consider investing some time in the looks and feel if you want to enjoy using it.
Things you may consider are:
Place the files are kept and file name convention
because your dashboard will look for information in external workbooks, ensure that the files are saved in a fixed directory and have a specific file name. if the external files are updated from time to time by other folks, let them know too that they have to save it in a particular folder with a specific name format.
Properly structure the source of data
Format you data source into tables so that it is easier for use with formulas. Throw away titles if any in the data source worksheet. Use tools like "Table" under the INSERT tab. When data are properly organized, they can be easily looked up using formulas such as VLOOKUP, SUMIFS, MATCH-INDEX, and COUNTIF.
Be good with formulas
Since we have no budget for VB, then good formulas will be needed. There are plenty of help on the internet for this I think you'll have no problem in it.
Employ sanitary check measure
It is difficult to tell if our formula isn't functioning properly when we have no counter check measure. Certainly you want to give your clients accurate information. One way to check is, think of alternative ways to get the information wanted and check if it matches to the first way. Another way is to retrieve a sequence of related information to be put on the dashboard, then do simple calculation to check if the numbers add up. Use conditional formatting to highlight errors if necessary.
I think these are key consideration, there may be more, but this is what i can think of for the moment.

how to display data that is related to a specific cell in excel 2010?

I have created 2 columns, the first has a category of a system using data validation, and the second has the description and failures of that system.
The purpose of that is to open a malfunction on some parts.
In a different sheet I wish to do the same only this time I want to choose the system and the description will automatically appear in the next column showing me all the malfunctions I have written on this system.
I am not very good at all the functions of excel. but I still searched for one that might help me. I have tried using the DGET function but it got me nowhere.
Perhaps try the solution here - it's a bit tricky to explain without copy-pasting the whole thing:
https://superuser.com/questions/536234/excel-how-to-vlookup-to-return-multiple-values
Also take a look at vlookup() if you're working across spreadsheets.
As expected, all of the responses you've seen ehere - and probably elsewhere - are ponyers to VLookup, or a refusal to answer your question.
I'm guessing that you're using DGET() because you need to retrieve data from one named column, using a match for a search term in another named column; and you're that because you can't rely on column ordinals or addresses - you have to do it by name.
VLookup won't do that for you: not without extremely complex and fragile array formulae.
The bad news is: Microsoft NEVER published a working example of a DGET() formula or any corresponding VBA Worksheet Function code.
There's page after page of descriptive text and general explanation in the helpfiles and on MSDN: but no working example. Nobody in Redmond ever sat down and made the DGET() function work with a reproducible set of function parameters and published a screen-shot the working formula.
I'll let you guess why that is.
Maybe there's an example somewhere that is, in effect, a VLookup implemented for known column ordinals using DGET(). If there is, I never found it and you won't either: and it would, of course, be useless for any application where you're working with field names instead of known ordinals.
What you need to do is capture the tabulated data range, with field names in the top row, and pass it to a SQL query using ADODB or MS-Query. That bad new for that is that all the MS-JET Excel drivers have a fatal memory leak.
After that fails, you're left exporting the data somewhere that a proper database app can run the SQL: and that's actually the right thing to do, because your attempt at using DGET() is a relational data query.
If you're left with the need to do this entirely in Excel, you have reached a level of desperation normally associated with the last survivor of an airplane crash who, having devoured the charred remains of his unlucky fellow passengers, is finally forced to contemplate the awful exigency of opening and eating the inflight catering meals.
The grisly details for the equivalent in Excel are a Horrible Hack published here:
http://excellerando.blogspot.com/2014/09/from-time-to-time-it-necessary-to.html

What is the best way to import data from sophisticated formula enriched Excel files into SalesForce.com?

My current employer (to remain nameless) has a collection of incredibly sophisticated Microsoft Excel 2003 worksheets (developed by contractors, also to remain nameless).
The employer is replacing the Excel-based solution with a SalesForce-based solution (developed by other contractors, likewise to remain unnamed). The SalesForce solution is also very complex using dozens of related objects and "Dynamic SOQL" to contain the data and formulas which previously was contained in the Excel-based solution.
The employer's problem, which has become my problem, is that the data from the Excel spreadsheets needs to be meticulously and tediously recreated in .CSV files so it can be imported into SalesForce.
While I've recently learned I can use CTRL-` to review formulas in Excel, this doesn't solve the problem that variables in Excel have cryptic names like $O$15. If I'm lucky, when I investigate $O$15, I'll find some metadata explaining if n cells up and/or some other data m cells to the left, and/or (in rare instances) there may be a comment on the cell.
Patterns within the Excel spreadsheets are very limited, rarely lasting more than 6 concurrent rows or columns and no two sheets which need to be imported have much similarity.
Documentation of all systems are very limited.
Without my revealing any confidential data, does anyone have any good ideas how I might optimize my workflow?
It's not clear exactly what you need to do: here are 3 possible scenarios, requiring increasing knowledge of Excel.
1. If all you want is to convert the Excel spreadsheets into CSV format then just save the worksheets as CSVs.
2. If you just want the data and not the formulae then it would be simple (using VBA) to output anything that isn't a formula (the cell.Formula won't start with =).
3. If you need to create a linkage excel-->csv-->existing Salesforce objects/SOQL then you will need to understand both the Excel Spreadsheets and the Salesforce objects/SOQL that have been created. This will be difficult unless you have good knowledge and experience of Excel and also understand what the salesforce App requires.
Brian, if you're still working on this, here's one way to approach the problem. I use this kind of process often for updating data between SFDC and marketing automation apps.
1) Analyze the formulae that you're re-creating in Salesforce.com to determine what base data fields you need (stuff that doesn't have to be calculated from something else.
2) Find those columns/rows in your spreadsheets and use Paste Special -> Values in a new spreadsheet to create an upload file with values instead of formulae that you need for each data area (leads, prospects, accounts, etc.)
3) If you have to associate the info with leads or contacts or accounts and you have already uploaded or created those records in Salesforce.com, be sure to export them with their ID numbers. That makes it easy to use the vlookup formula in Excel to match up fields that you need to add and then re-upload the data into Salesforce.
Like data cleaning, this can be a tedious process. But if you take it step by step it shouldn't be too hard. Good luck.

How use to write programme that involve with a lot of active calculation? In excel 1M+ Row and 20+ column

First, I dont have any experience with programming. If I ever start, then this would be probably my first. I keep looking for answer until I found this site.
I am looking outside the box because in excel doing a data of 1 million + row and 20 + column would take a very long time just to wait for the calculation to be done and the copy and paste with formula would take longer. Imagine I have to let the computer running for 8+ hours with the helps of marco and F4 (repeat). All my formula have to paste into number only with I have done with the formula. And even I break the files into piece, the files sizes are 20MB to 110MB without active formula. Opening the file is taking forever.
I wonder how to write a programme with 1) dialog box, 2) the excel command and formula (sort, delimiter, concatenate), 3) ability to create graph, 4) with tabs to view different set of data or graph 5) add in a set of data 6) limiting the number (1-100000), etc. Outlook something look like utorrent.
What compiler suitable for this programme? It's easier you tell me which 'book' to read that me finding which 'book' is suitable because even if it is I might flip it through and go on to the next one. 'book' may refer to book, way, steps, etc.
I'm not sure what you actually want. With 1M+ rows and 20+ columns, an Excel sheet doesn't seem to be the right tool for the job. So do you...
want to keep using Excel, but automate the job? Use Excel VBA like renick suggested. It's the language that Excel uses internally for macros, but you can write any kind of automated processing you'd like. Beware, however, that VBA is not exactly the best language to start a programming experience with. (That's my personal opinion, and what matters is of course whether you get the job done).
want to switch to something else? A database management system seems better suited for the amount of data you have. Microsoft Access is part of Office and might already be on your system. Getting your data into and out of the database could be a problem, but the advantage you have is that a database is built to handle colossal amounts of data and will happily munch your figures for several days without failing. You can access the data using the Structured Query Language (SQL), which is not really a programming language, but very powerful (and it most certainly has CONCATENATE, ADD etc.). Graphing is more difficult, but can also be done.
If you know excel then Excel VBA is a VERY capable language to do all this. I would suggest you go to the VBA Dev Center here to get started.
I can't believe I'm about to say this (for most things I do it would be the wrong choice) but:
If the computations aren't that complex (just lots of them) Python might be a good bet.
If you can get the input as a CSV file than, for about 10 lines of code, you can write a loop that will be run for each line of input and hands you the values to play with.
for line in open('filename', 'w')
values = line.split(',')
#values has the values from this line as strings.
#these can be converted to numbers:
x = float(values[0])
n = int(values[1])
#... and then processed
That might not be the cleanest/best approach but it's simple and straight forward.
p.s. For 1M+ rows, don't expect it to be blazing fast (10 sec to a min or so, depending on what you do to the data)

Resources