Excel VBA functions

I have learned how to make my own Yield function by 
writing the code in the VBE window.  However, it is saved 
in my personal macro workbook and everytime I want to use 
it, I have to type out PERSONAL.MYield.MYield
([arguments]).  Is there a way to make it so that I can 
just type MYield([arguments])?

Bonus - Is there another, more user friendly way to make 
your own functions in Excel?
0
anonymous (74722)
1/5/2004 6:40:47 PM
excel.misc 78881 articles. 5 followers. Follow

2 Replies
352 Views

Similar Articles

[PageSpeed] 32

Hi Mokey

Check your personal.xls in the VBA editor
Tools>References
You don't have to type the filename then

-- 
Regards Ron de Bruin
(Win XP Pro SP-1  XL2000-2003)
www.rondebruin.nl



"Mokey" <anonymous@discussions.microsoft.com> wrote in message news:004a01c3d3bb$6f4df170$a501280a@phx.gbl...
> I have learned how to make my own Yield function by
> writing the code in the VBE window.  However, it is saved
> in my personal macro workbook and everytime I want to use
> it, I have to type out PERSONAL.MYield.MYield
> ([arguments]).  Is there a way to make it so that I can
> just type MYield([arguments])?
>
> Bonus - Is there another, more user friendly way to make
> your own functions in Excel?


0
rondebruin (3790)
1/5/2004 7:56:44 PM
Is that in a form code module or a general module?
Make the function public in a general module.

Public Function MyYeild()

Not

Private Function MyYeild()...

-- 
John
johnf 202 at hotmail dot com


"Mokey" <anonymous@discussions.microsoft.com> wrote in message
news:004a01c3d3bb$6f4df170$a501280a@phx.gbl...
| I have learned how to make my own Yield function by
| writing the code in the VBE window.  However, it is saved
| in my personal macro workbook and everytime I want to use
| it, I have to type out PERSONAL.MYield.MYield
| ([arguments]).  Is there a way to make it so that I can
| just type MYield([arguments])?
|
| Bonus - Is there another, more user friendly way to make
| your own functions in Excel?


0
me5306 (285)
1/5/2004 10:52:39 PM
Reply:

Similar Artilces:

Excel 97 #11
How can I change a spreadsheet , so that it opens on sheet 1 every tim someone goes into it , when working on the spreadsheet, it will ope the last page that a save was done on. Thanks -- Message posted from http://www.ExcelForum.com Your 1st question. Save at the sheet desired or use an auto_open macro in a regular module or a workbook_open event in the ThisWorkbook module that uses sheets("yoursheetname").select -- Don Guillett SalesAid Software donaldb@281.com "EADesktop >" <<EADesktop.163m60@excelforum-nospam.com> wrote in message news:EADesktop.163m6...

Is is me? Or is Excel 2007 Charting Lame?
Maybe I'm missing something. If so, let me know. The process of creating a chart is unintuitive and cumbersome. A big step backwards from 2003. The manual says to just select your data and insert the chart. What I find is that 95% of the time, I have to re-do the data selection. If I highlight two columns and insert the graph, Excel thinks both columns are two different series instead of x and y axis. I create two columns, label one of them "X", one of them "Y". Put some numbers below that. Now insert an XY chart. One would think that it could figure out "...

Adding a column in Excel 2007
Have a column with letters in it. Want to sum up how many of one letter I have in the column. What is a formula to do this please To count the number of cells that equal X =countif(a:a,"X") To count the number of cells that have at least one X in them: =countif(a:a,"*X*") nip wrote: > > Have a column with letters in it. Want to sum up how many of one > letter I have in the column. What is a formula to do this please -- Dave Peterson On Dec 10, 10:44=A0am, Dave Peterson <peter...@verizonXSPAM.net> wrote: > To count the number of cells that eq...

excel process in the background
I'm trying to find a way of updating the excel spreadsheet without the excel application coming up on the users PC. We are getting input from the WEB and using that input to run a model and capture the data in an excel spreadsheet. Then manipulate the spreadsheet and create a summary Word document that will be emailed to the user. Then the user will be emailed with the summary data from the excel document. The thing is that this will be running on some server and I don't want the excel spreadsheet or application to actually come up on the PC. How can I suppress the applicati...

Shared use of excel work books
Hi, Can anyone tell me "if I have an excel workbook (with multiple worksheets that report to the first worksheet) on a shared drive whether it can be set up for multiple users to access it and use it at the same time?" These users will be accessing their single worksheet to update it periodically with the first worksheet being the project leaders sheet where he gets to see all the other worksheets on his one sheet. -- Ian Hi Ian, You can do this by selcting "shareworkbook" from the tools menu and checking the 'allow changes by more than one use'. Beware th...

Line graphs; excel 2007
I have a simple line graph - and I'd like to shade in the area btwn the two lines only (not the whole background of the graph). Any suggestions? Apply Fill Color Between Lines in a Chart http://pubs.logicalexpressions.com/Pub0009/LPMArticle.asp?ID=590 - Jon ------- Jon Peltier Peltier Technical Services, Inc. http://peltiertech.com/ MK09 wrote: > I have a simple line graph - and I'd like to shade in the area btwn the two > lines only (not the whole background of the graph). Any suggestions? ...

Help with functions
If I have the following formula in a worksheet to bring up a message box =IF((F4-E4)>=10,Amend()+F4-E4,F4-E4) How can I use a function to transfer some information from different cells to a new worksheet if the formula above works? You can't have a function transfer information to another cell, it will return it's info in the cell where it's located, you would need a formula(s) in the cells where you want this information. Otherwise you would need VBA Regards, Peo Sjoblom "Monty" wrote: > If I have the following formula in a worksheet to bring up a me...

IF Function #6
Hello, I want to use the IF function to perform certain calculation based on a value in a cell. I can manage that without a problem however my problem comes up when i want to use a range using OR within IF Lets say you have A1 with a value and you want certain value to be calculated based on it. IF A1 < 50,000 then it should do something but IF A1 is greater than 50,000 BUT less than 180,000 then it should do something, however IF A1 is greater than 180,000 and less than 250,000 then is should do something. I can manage the first bit but failing with the second comparison. Here'...

Using the "IF" function?
I setup a worksheet like below A B 1 Jan 123 2 Feb 543 3 Mar 654 4 Apr 456 5 May 645 6 Jun 543 7 Jul 0 8 Aug 0 9 Sep 0 10 Oct 0 11 Nov 0 12 Dec 0 13 When the end of the month, the user will enter some value in the B column, And now I would to setup a formula at A13, if the user enter the value in the B7, then the A13 will show Jul, when the user carry on to enter the value in the B8, then the A13 will change to show Aug, is it possible to setup a if formula or other formula rather than use the macro to doing this? Many Thanks. Ruff Try this: =INDEX...

Problem with vba directory function
Hi We have an access application that has a button when clicked opens an excel worksheet showing all exported data based on code The access sql system is in Citrix with a single front end copy. Here is the code part that is throwing the error for just one user. Rest all are working fine Dim strSourceFileName As String Dim WorkBookName As String strSourceFileName = "c:\CarLogOutPut\CarLogExportTemplate.xls" WorkBookName = "c:\CarLogOutPut\CarLogExport.xls" If Dir(strSourceFileName) = "" Then MsgBox "CarLogExportTemplate.xls doe...

Microsoft Excel ASC II Text Files
How do I convert an Excel spreadsheet into this type of file in order to import to another program such as "MaiList & AddressBook" Hi Bill try saving as 'CSV' file in the Save As dialog. This is a comma separated text (ASCII) file HTH Frank Bill Cadwallader wrote: > How do I convert an Excel spreadsheet into this type of > file in order to import to another program such > as "MaiList & AddressBook" ...

EXCEL 2003
hi Im performing Logical boolean operations using MS Excel. The only problem is that its displaying result set as "TRUE/FALSE" and I want to have the result in binary. Is there a way to convert that text "TRUE" into digit "1"? please tell me ASAP. thank "imfaizzi" <imfaizzi@discussions.microsoft.com> wrote: > Is there a way to convert that text "TRUE" into digit "1"? =--(A1>A2) returns 1 for TRUE and 0 for FALSE. Similarly for =1*(A1>A2) "imfaizzi" <imfaizzi@discussions.microsoft.com> wrote ...

Excel Services Publish
I have a 64 bit client (Windows Server 2008) and my colleague has Windows 7 64 bit client. We are trying to publish an Excel 2007 document to MOSS, which is running under https, and is sitting on a 64 bit operating system. We keep getting the "File Not Saved" error when we try to publish from our clients. However, a 3rd colleague has Windows XP 32 bit and can publish the same exact Excel files just fine up to the very same MOSS location we tried on the 64 bit clients. Can someone from MSFT confirm that this is an issue with 64 bit clients? Can you present a solut...

Excel pivot tbl
Brand new laptop w/Windows XP. Has Office 97 installed (first), than complete install of Office XP(second). Than install of PTSfull.exe (pivot table services that come w/ sql server analysis services service pack 2). Go to data manu - PivotTable and Pivot Chart report - External data source/Pivot table - Get Data - OLAP cubes - new data source - select an olap provider for the database you want to access - blank dropdown (no Microsoft OLEDB Provider for OLAP Services or Microsoft OLEDB Provider for OLAP Services 8.0). Tried removing Office 97 & Office XP than installing PTS - sa...

Date formatting in Excel #2
How do I format a cell to return Oct 04 when I type 10-4 in Excel...When I type 10-4, Excel returns Oct 05. Hi When no year is typed, excel would assume it is the current year. You would ahve to type the full date (including 2004) for it to display as Oct 2004. Use Format - cells - date and then select the particular format you want from the options there. >-----Original Message----- >How do I format a cell to return Oct 04 when I type 10-4 in Excel...When I >type 10-4, Excel returns Oct 05. >. > ...

excel #136
I have files in quantrum pro and would like to open them in excel. But they won't popen I'm not familiar with Quantrum Pro. What does it do? "Liz R" wrote: > I have files in quantrum pro and would like to open them in excel. But they > won't popen ...

Excel worksheet merge
Hello all, I have searched google, but to no avail. Here goes. I have one set of excel worksheets (one is an exact link to the other) that I copied four times for a total of five. I moved the 1st worksheet of each to an individual folder. So what I am left with are the 5 link worksheets. Can I merge the links together? I have an Access db that I will use to process the info. I have linked the links to an Access db and it works. Except I have 5 dbs instead of the one that I really need. The fields are the same in all linked dbs. My question is- should or can I merge before access and i...

Data Validation in XL2007 suddenly stops functioning
I created a workbook in XL2003 that included some named ranges on Sheet2 that fed some data validation lists on Sheet1. Everything worked as expected. My colleague opened up the workbook in XL2007 and used it several times, and everything worked as expected. Then she called me, saying that it was broken. Of the 6 named ranges and related data validation columns on the other sheet, none of them were working anymore. I went over to her PC, and checked everything I could think of- I could set up working data validation test cells on Sheet2, but could not get the ones on Sheet1 to...

retaining fonts when placing excel worksheet into pagemaker?
I am currently placing excel worksheets into Pagemaker software. I am having particular trouble with retaining the fonts in the text cells. When it appears in pagemaker the spacing is wierd and the numbers eg.(12/8) are crammed together. I used excel 2003. I am not a pagemaker wizard soooooooooo please help. Cindy I think PageMaker will let you Edit-->Paste special-->as a picture, won't it? Sorry, it's been a long time... ******************* ~Anne Troy www.OfficeArticles.com www.MyExpertsOnline.com "parrydise" <parrydise@discussions.microsoft.com> wrote i...

Templates Excel XP
Where can I find templates to download to Excel XP. I'm looking for templates for both business and personal use http://office.microsoft.com/en-us/default.aspx -- Regards, Peo Sjoblom (No private emails please) "sfrich1" <sfrich1@discussions.microsoft.com> wrote in message news:B7C932BB-3DE7-440C-B4E0-511EC8527F07@microsoft.com... > Where can I find templates to download to Excel XP. I'm looking for > templates for both business and personal use If you forget the address in the future, go to Excel's menu, and select Help | Microsoft Office Onl...

Excel macros page breaks but not on row 1 and column value in footer
Hi, I have seen some posts that are similar, but no one seems to have the problem that I am having. I will post my macro in this, for anyone that is interested. My users get a csv file every month, and we have to clean it up. This macro does that. My last issues are this: 1) having the spreadsheet create page breaks whenever the value in column B changes. Below is just that code. Code: col = 2 LastRw = ActiveSheet.UsedRange.Rows.Count For X = 2 To LastRw If Cells(X, col) <> Cells(X - 1, col) And Cells(X, col) <> Range("B1") Then ActiveWindow.SelectedSheets.HPageBreaks...

When Excel Opens it Starts with Book2
Anyone know why excel would open to book2 and not book1. Hi Tracey! This means that a file with the Book1 name has already been saved. Find it using Start > Search > For Files and Folders Check the contents and either rename or delete. -- Regards Norman Harker MVP (Excel) Sydney, Australia njharker@optusnet.com.au Excel and Word Function Lists (Classifications, Syntax and Arguments) available free to good homes. ...

Does Pocket Excel run VBAs?
I have desktop spreadsheets with VBAs - would they work in a Pocket PC/Pocket Excel environment? Hi F Chuck! Sorry but Pocket Excel does not support VBA. -- Regards Norman Harker MVP (Excel) Sydney, Australia njharker@optusnet.com.au Excel and Word Function Lists (Classifications, Syntax and Arguments) available free to good homes. "F Chuck" <anonymous@discussions.microsoft.com> wrote in message news:076601c3c44f$78706c40$a101280a@phx.gbl... > I have desktop spreadsheets with VBAs - would they work > in a Pocket PC/Pocket Excel environment? ...

create pivot table formula without the GETPIVOTDATA function
Previous to Excel 2003 I could use a pivot table result in a formula and copy that formula as a relative reference. In Excel 2003 a GETPIVOTDATA fromula is created and uses an absolute reference. Is there a way in Excel 2003 to either make it arelative reference (without editing the formula) or revert to the method used in all prior releases? There are instructions here for adding the Generate GetPivotData button to a toolbar, and toggling the feature on and off: http://www.contextures.com/xlPivot06.html ebergkes wrote: > Previous to Excel 2003 I could use a pivot table resu...

VBA Help #4
Hi, I have a list of clients with their associated outstanding dollar amount and their return (%). I would like to know if there is code that would allow me to break up these clients by return (%) groupings. For example, I would like to group below 10%, 10% to 17%, and above 17%. So at the client on the list that is just before 10% I would like to add two rows and put a dollar subtotal in the immediate row and sum the dollar amounts. Can anyone help? Thanks, Marino Public Sub ProcessData() Const TEST_COLUMN As String = "A" '<=== change to suit Dim i As Long Dim LastR...