how to use the search dialog box ?

Hello Everybody,
I have a question concerning the opening of dialogs box. I would like to 
open the Search Dialog Box. My stupid code is like this :

Private Sub CommandButtonSearch_Click()
     'ouvre la boite de dialogue Rechercher
     Application.Dialogs(xlDialogFormulaFind).Show
End Sub

With this code, the problem is that the Search Dialog box is indeed open 
but whatever the text to find in the worksheet, there is no result. If I 
stop the macro, open by hand the Search  Dialog box and type the same 
text, it works... Can you help me to solve this problem ?
Thanks a lot in advance.
Cyrille
0
2/15/2005 6:10:28 PM
excel.newusers 15348 articles. 2 followers. Follow

2 Replies
508 Views

Similar Articles

[PageSpeed] 11

Some or all Excel versions before Excel 2000 had this problem.  When run 
from a macro the way you're doing it Excel would only search the range 
selected when the macro is run.  This is usually just one cell.  One way to 
overcome this:

Private Sub CommandButton1_Click()
    Cells.Select
    Application.Dialogs(xlDialogFormulaFind).Show
    ActiveCell.Select
End Sub

This was fixed in Excel 2002 and later.

-- 
Jim Rech
Excel MVP
"cyrille" <patchaltair@hotmail.fr> wrote in message 
news:42123b1f$0$3832$626a14ce@news.free.fr...
> Hello Everybody,
> I have a question concerning the opening of dialogs box. I would like to 
> open the Search Dialog Box. My stupid code is like this :
>
> Private Sub CommandButtonSearch_Click()
>     'ouvre la boite de dialogue Rechercher
>     Application.Dialogs(xlDialogFormulaFind).Show
> End Sub
>
> With this code, the problem is that the Search Dialog box is indeed open 
> but whatever the text to find in the worksheet, there is no result. If I 
> stop the macro, open by hand the Search  Dialog box and type the same 
> text, it works... Can you help me to solve this problem ?
> Thanks a lot in advance.
> Cyrille 


0
jrrech (1932)
2/16/2005 12:17:33 AM
Jim Rech wrote:
> Some or all Excel versions before Excel 2000 had this problem.  When run 
> from a macro the way you're doing it Excel would only search the range 
> selected when the macro is run.  This is usually just one cell.  One way to 
> overcome this:
> 
> Private Sub CommandButton1_Click()
>     Cells.Select
>     Application.Dialogs(xlDialogFormulaFind).Show
>     ActiveCell.Select
> End Sub
> 
> This was fixed in Excel 2002 and later.
> 
Thanks a lot for your help !
Very nice to see such a compatibility ... ;-)
0
2/17/2005 10:28:16 PM
Reply:

Similar Artilces:

Help with front page drop down box
Hi, i need to know how to direct people to the drop down option they select from a website Try this: http://www.echoecho.com/tooldropdown.htm -- ~ Kathleen Anderson Microsoft MVP - Expression Web Spider Web Woman Designs Expression Web Resources: http://www.spiderwebwoman.com/xweb/ Expression Web Wiki: http://expression-web-wiki.com/ FrontPage Resources: http://www.spiderwebwoman.com/resources/ Please reply to the newsgroup for the benefit of others "Michael" <icouldbeelvis@discussions.microsoft.com> wrote in message news:8309C283-377B-4A6B-A7FD-3A6508...

Big Ask? Loading UserForms and then using the Check Box
I am very new to VBA and am trying to do the following, I have created the Userform and check boxes but that is as far as i can go. When a ceratin a cell e.g A1 goes to = red then a userform will pop up with a list of check boxes e.g Nexus, G2, Swift, Crest if Nexus and Crest check box is ticked then the word nexus will appear A2 and Crest in A3. Or if G2 and Swift were checked then G2 would be in cell A2 and Swift in cell C3. Many Thanks Changing the format of a cell isn't enough to make excel notice the change. But you could tie showing your userform to a change in a column (or...

'Assign Macro' dialog missing in Excel XP
I'm trying to assign a macro to a command button, however the 'Assign Macro' dialog is missing from the context menu when right clicking the button. I have only been to do it when having opened an old worksheet (created in excel 97) with existing command buttons & macros, then the option is there to assign a macro. I have searched the net for a solution however to no avail. I know it is possible since Excel Help states that is the official way to do it. I have office Xp installed with service pack 2. I hope you will be able to help me. Thank you It's possible ...

What FONT does Excel Viewer use?
Just a quick question. What FONT does Excel Viewer use? Anyone know? I'm trying to match it manually in Photoshop but I can't seem to figure out which one it is. Thanks! Using version 8 - it uses the same font as in the worksheet. If you are finding differences it may be that the original is not available on your machine and Windows/Excel is sustituting. --- Message posted from http://www.ExcelForum.com/ ...

How use Property sheet from a DLL library?
Hi, All, I want to create a common extension DLL library that only includes one property Sheet with more than one property pages. this DLL also includes a invoke API that can be called by Win32 application. my problem is that I can't Add property pages to property sheet and error message shows Resource was unvailable inside invoke API. below is some sample code: In MyProp.dll includes these: 1) void InvokeApi(HWND Hwnd, HINSTANCE hLib, ...); 2) class CPage1: public CPropertyPage{ ...} 3) class CPage2: public CPropertyPage{ ...} 4) class CMySheet: public CPropertySheet{ ...} here is I...

input box upon workbook open
I want to have an input box that will ask for a date when a workbook is opened. I want to be able to us the date that is input in code that will be run from a macro. The reason I want the input box upon open instead of when the macro is run, is because the end user uses the file repeatedly for multiple calculations. This date will be applied to all of the calculations, and I don't want the user to have to enter the same date over and over. I assume that I need something like a "public enddate as date" in the ThisWorkbook object. This however doesn't work. What do I need ...

Search by Form with Checkboxes
I have Access 2003. One of my Tables has multiple fields with the Data Type Yes/No and a Display Control of Checkbox. I have a query by form with multiple text boxes and a related query. One of my query examples is listed below. Like "*" & [Forms]![F_CatSearch]![txtGumChewing]. I need to be able to make multiple selections for my query's output. My problem is in the form I have to put "-1" in the field for my query to work. I want to be able to have a checkbox in my form so the user can check the items they want selected in the query. Can anyone help...

which query is faster, better to use?
There are multiple AdjournmentDates for any given NoticeID in tblNotices_AdjournemntDates. I want the most recent date for each NoticeID. Both of these produce the correct results. Is either one better than the other? SELECT DISTINCT NoticeID, (SELECT TOP 1 AdjournmentDate FROM dbo.tblNotices_AdjournmentDates WHERE NoticeID = A.NoticeID ORDER BY AdjournmentDate DESC) FROM dbo.tblNotices_AdjournmentDates A SELECT NoticeID, AdjournmentDate FROM dbo.tblNotices_AdjournmentDates A WHERE (AdjournmentDate IN (SELECT TOP 1 AdjournmentDate FROM tblNotices_AdjournmentDates WHER...

Using Junk Email with Rules *not answered*
The Junk Email "spam filter" in Outlook 2003 does not appear to work on email that is moved to other folders using Rules (i.e. for people with multiple email accounts). Is there a work around to this? Perhaps some way to modify the rules so Junk Email will get filtered? Going thru 300 spam emails a day by hand = not fun. -Max I'm having the same problem. Does anyone know why this is occuring?? >-----Original Message----- >The Junk Email "spam filter" in Outlook 2003 does not appear to work on >email that is moved to other folders using Rules (i.e. for ...

Configuring Outlook to use MSN account
I have an MSN account and email address. How do I configure Outlook to use my MSN account to receive/send email I may be wrong but I think you configure the account as an HTTP mail account. "GKW in GA" <GKWinGA@discussions.microsoft.com> wrote in message news:24240C12-A267-4D50-9573-B2EACFF134C6@microsoft.com... >I have an MSN account and email address. How do I configure Outlook to use >my > MSN account to receive/send email You will need to find out from MSN what the POP3 and SMTP server names are and what the proper procedure is for setting them up in Out...

Using Rational Purify on MFC Code
Does anyone have experience using Purify on C++/MFC code. I am getting a lot of MPKs and MLKs that appear to be in Microsoft code. For example the following output from Purify is for a memory leak from MQOpenQueue(). [W] MLK: Memory leak of 36 bytes from 1 block allocated in CMSMQQueue::Open(CString) Distribution of leaked blocks Allocation location LocalAlloc [KERNEL32.dll] CMSMQQueue::Open(CString) [MSMQQueue.cpp:51] WCHAR wszQueueName[ 256 ] = {0}; mbstowcs( wszQueueName, sQueueName, sQueueName.GetLength() ); => hRes = MQOpenQueue( wszQu...

RPC-http using single server
I'm trying to follow the instructions in the MS paper "Exchange Server 2003 RPC over HTTP Deployment Scenarios" to configure my Exchange 2003 Enterprise server to use RPC over HTTP in a single server installation. I don't have "RPC-HTTP" tab in my server properties dialog in ESM! I thought everything was ready up to this point, but I've obviously missed something. Any ideas? TIA, Bob D'oh! In "networking services" of Windows setup of the Exchange server, RPC proxy wasn't installed by default... "Bob" wrote: > I'm trying...

Entering array formula using VBA
The following is an array formula.... =IF(OR(G26="",VLOOKUP(G26,$G$16:$H$23,2,FALSE)=0),"",MAX(IF($G$16:G26=G26,$H $16:H26)+1)) 1. Is there a way to enter this into the cell (G26) using VBA (as an array)? 2. If so, if the row that this is to be entered is diff to row 26, how does this get entered into say, G35 and the references changed appropriately? Rob Hi Rob, try this Sub rob() Range("F26").FormulaArray = "=IF(OR(G26="""",VLOOKUP(G26,$G$16:$H$23,2,FALSE)=0),"""",MAX(IF($G$16:G26=G 26,$H$16:H26)+1))" ...

how do I customize my menubar using a2007?
I've move to A2007. The menubar I created in A2003 is still there but how do I now customize it? Jesper I believe that you can only customize it in Access 2003, since 2007 doesn't use menubars anymore. -- Arvin Meyer, MCP, MVP http://www.datastrat.com http://www.mvps.org/access http://www.accessmvp.com "Jesper F" <jesperfjoelner@hotmail.com> wrote in message news:47e24896$0$90274$14726298@news.sunsite.dk... > I've move to A2007. The menubar I created in A2003 is still there but how > do I now customize it? > > Jesper > >I believe tha...

Excel File in Use Notification Missing??
We are using Windows Server 2000 & several versions of Excel (2000 / XP / 2003). When opening Excel files from the network, SOME users get the Notification that the File is In Use - locked for editing by <user> - with a choice to Open as Read-Only, Notify when avail, or Cancel. The pblm is that NOT EVERYBODY gets this msg - some simply have the file open up with the word (Sharing) in the Title Bar!! When you've got a deskful of work to input you're not always looking at the Title Bar to see if the file is Shared or not. I first thought this was caused by diff vers o...

Using OWA how can I find out the size of my mailbox?
Hi I use OWA at University. How can I easily verify the size of my mailbox ? Thanks Jay ...

Query with Combo Boxes on a Form
I'm using QBF with about six different combo boxes using: [forms]! [formmain]! [combo1] or [forms]![formmain1]![combo1] -like in a VBA book. This is so users can select criteria on a form with the combo boxes, and when they are done, they hit the search button, and it opens up another form based on the query just performed by the combo selection. This worked for about three combo boxes, but when I added another one, it freezes up and opens up a blank page. It's supposed to open the new form based on the query. Is there a better way to do this? Any help would...

Using Brackets in Excel
I would like to know how to show negative numbers in an Excel worksheet in brackets rather than a minus sign in front of the number. Thanks and regards On Mon, 18 Aug 2003 02:50:05 -0700, "Robert" <Robert@kellyassociates.biz> wrote: >I would like to know how to show negative numbers in an >Excel worksheet in brackets rather than a minus sign in >front of the number. > >Thanks and regards Format/Cells/Number/Custom/Type: 0.00_];\[0.00\] --ron Hi Robert Select the Cells that you whish to apply formula to then, from the Format Menu select Cells, then s...

Searching for a letter #2
Thanks guys, I thought it might be simple..... but not that simple! Dan -- Voodooda ----------------------------------------------------------------------- Voodoodan's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=59 View this thread: http://www.excelforum.com/showthread.php?threadid=31372 ...

Using Office 2004 and Office 2008 on the Same Computer
Hello all, Is it possible to install say Word 2004 and Excel 2004 and Entourage 2008 and Powerpoint 2008 on the same computer? Alternatively, can I buy a Apple Script recorder so that I can easily create Apple Macros? Then I wouldn't care if I had Word and Excel 2004... Regards to all! JP On 4/30/08 10:57 AM, in article 3f85aac8-1b31-44b6-9fd9-9f383cae765d@k13g2000hse.googlegroups.com, "jpensuisse@gmail.com" <jpensuisse@gmail.com> wrote: > Hello all, > > Is it possible to install say Word 2004 and Excel 2004 and Entourage > 2008 and Powerpoint 2008 on th...

Excel not using regional settings
Hi - I have set my regional settings to use brackets (23) for negative numbers. I've set both the number and currency formats to use brackets for negative number. WHen starting Excel, using a new blank workbook, negative numbers entered into a cell do NOT show with brackets? My language is set to English (US) and I've adjusted the formats to use brackets for negative numbers and I've copied to reservered accounts. I also want the date to default to the short date format I've set for the language but it too is not working. Excel will not use the default formats I...

Creating a Report using two queries
I have created a chart report (bar chart) using one query. How can I create another single chart showing the results of both queries. One will show the bars of first query data and the other will show bars of the data from second query together in a single chart report. Any suggestions? -- FL This depends on how/if the two queries are related. I would expect the "X" axis values might be related. If so, join the two queries into a single query and graph the new query. -- Duane Hookom Microsoft Access MVP If I have helped you, please help me by donating to UCP http://www...

Text Box
I would like to have the same size text box on multiple pages that are linked. I have tried right clicking the text box, selecting Format Text Box and checking Apply Settings to New Text Boxes, but it doesn't appear to work. When I add text to the box and it runs out of space, Publisher asks if I want to insert a new text box and connect it, and I accept, the new text box is the wrong size, and sometimes comes in with a black border rather than the no line border I have designated. Is there another method to easily accomplish what I want? I have read several posts that recommend...

can not open excel files using associations
Hi, I am having problems to open an excel spread sheet by double clicking on the file itself. Please, any ideas? Thank you Marcela Try Tools>Options>General and un-check 'Ignore other applications' -- HTH Nick Hodge Microsoft MVP - Excel Southampton, England nick_hodgeTAKETHISOUT@zen.co.uk.ANDTHIS "Marcela Pruk" <marcelapruk@lubtec.sk> wrote in message news:%23Fv9hCjIFHA.720@TK2MSFTNGP10.phx.gbl... > Hi, > I am having problems to open an excel spread sheet by double clicking on > the file itself. Please, any ideas? > Thank you > And ...

Search text in folder of publisher files?
Can you search text in folder of publisher files. Google desktop style of program, but pub files are not on supported list. -- ks_paper ...