+ Reply to Thread
Results 1 to 3 of 3

how do I assign the replace function to a macro in excel?

  1. #1
    Vish617
    Guest

    how do I assign the replace function to a macro in excel?

    I would like to create a macro that executes the 'replace' function in Excel,
    can anyone please tell me how this can be done? Thanks.

  2. #2
    Duke Carey
    Guest

    RE: how do I assign the replace function to a macro in excel?

    Without writing code, the best you can do is record a specific search &
    replace, always duplicating the same search & replace. In other words, if
    you record while searching for "Gore" to replace it with "Bush", that's what
    the macro will always do.

    If that's adequate for your purposes, simply record it and save it in your
    Personal Macro Workbook. If you don't have a Personal Macro Workbook yet,
    don't worry, Excel will create it for you. When you close Excel, be sure to
    save changes to the Personal Macro Workbook when prompted to do so. Then
    your macro will be available every time you run Excel.

    "Vish617" wrote:

    > I would like to create a macro that executes the 'replace' function in Excel,
    > can anyone please tell me how this can be done? Thanks.


  3. #3
    Vish617
    Guest

    RE: how do I assign the replace function to a macro in excel?

    The type of macro I need will probably require code.
    The following code opens the 'Edit' box by going to Tools>Options and then
    the Edit tab:

    Sub ShowOptions()
    Application.Dialogs(xlDialogOptionsEdit).Show
    End Sub

    I need it to open the 'find & replace' dialog window. Any idea on whether
    this can be done and how? Thanks

    "Duke Carey" wrote:

    > Without writing code, the best you can do is record a specific search &
    > replace, always duplicating the same search & replace. In other words, if
    > you record while searching for "Gore" to replace it with "Bush", that's what
    > the macro will always do.
    >
    > If that's adequate for your purposes, simply record it and save it in your
    > Personal Macro Workbook. If you don't have a Personal Macro Workbook yet,
    > don't worry, Excel will create it for you. When you close Excel, be sure to
    > save changes to the Personal Macro Workbook when prompted to do so. Then
    > your macro will be available every time you run Excel.
    >
    > "Vish617" wrote:
    >
    > > I would like to create a macro that executes the 'replace' function in Excel,
    > > can anyone please tell me how this can be done? Thanks.


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1