Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

goal seek and problem

Forum home » Delegate support and help forum » Microsoft Excel VBA Training and help » Goal Seek and problem solving excel function using VBA

Goal Seek and problem solving excel function using VBA

ResolvedVersion 2007

Vivek has attended:
Excel VBA Intro Intermediate course

Goal Seek and problem solving excel function using VBA

Hello,

What is the general syntax and do we need to include any inbuilt library functions for the same?


Thanks,
Vivek

RE: Goal Seek and problem solving excel function using VBA

Hi Vivek,

Thank you for your question and welcome to the forum.

I have attached a spreadsheet with an example of VBA Goal Seek code. When you run the macro via the command button it will prompt you for a goal value(A1) and will then change cell B1 to achieve that goal.


The inbuilt functions are accessed by using the following line of code:

application.worksheetfunction.sum

I have attached a spreadsheet showing you the goal seek example.

I hope this answers your question.

Regards

Simon

Attached files...

Goal Seek VBA.xls

Thu 15 Dec 2011: Automatically marked as resolved.

 

Training courses

Training information:

Welcome. Please choose your application (eg. Excel) and then post your question.

Our Microsoft Qualified trainers will then respond within 24 hours (working days).

Frequently Asked Questions
What does 'Resolved' mean?

Any suggestions, questions or comments? Please post in the Improve the forum thread.

Excel tip:

Create own ribbon tab - Excel 2010

a. In Excel click on the File tab
b. Select Options from left hand side
c. Choose the Customize Ribbon section
d. Click the New Tab button (below the list of tabs on the right hand side of the dialog box)
e. Select the New Tab (Custom) and enter a name, by clicking the Rename button (below the list of tabs on the right hand side of the dialog box)
f. Select the New Group (Custom) and enter a name, by clicking the Rename button (below the list of tabs on the right hand side of the dialog box)
g. Add commands to your tab and group by locating them on the list on the right hand side (remembering that you can change the list using the drop down box at the top of the list of commands) and clicking the Add button between the two panes to add them to your tab and group
h. You can rearrange the commands in your group, the groups on any tab or the tabs, using the up and down arrow buttons beside the list of tabs.
i. Click OK to apply your changes

View all Excel hints and tips

Connect with us:

0207 987 3777

Call for assistance

Request Callback

We will call you back

Server loaded in 0.09 secs.