Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 51
Default Open Excel from a VB6 application then use "Find and Replace" form

Hi all,
I need to open Excel from an VB6 application and run the "Find and Replace"
form using a value that the VB application has it.
I like the "Find and Replace" form better that using regular code because it
has an window that opens and shows what are the search results.
Any suggestion is welcome!!!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Open Excel from a VB6 application then use "Find and Replace" form


You can use the standard built in dialog like this

Sub test()

Set FindDialog = Application.Dialogs(xlDialogFormulaFind)

Results = FindDialog.Show ' results is a boolean

MyResults = ActiveCell.Value

End Sub


I've never been able to figure out how to get the results from htis
dialog. It seems to only bring up a tool that the user can use but not
the VBA code.

The parameter are :
text, in_num, at_num, by_num, dir_num, match_case, match_byte

So you can use the following to find the string 123

Results = FindDialog.Show(arg1:="123")


--
joel
------------------------------------------------------------------------
joel's Profile: 229
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=163850

Microsoft Office Help

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 51
Default Open Excel from a VB6 application then use "Find and Replace"

Thank you so much Joel. Sorry for the delayed "Thank you!", I couldnt find my
thread in the web site..now I learned how to do it...

Thank you so much for helping me. It will be a pleasure to show you the
final result if you wish to...

Happy New Year and all the best!

"joel" wrote:


You can use the standard built in dialog like this

Sub test()

Set FindDialog = Application.Dialogs(xlDialogFormulaFind)

Results = FindDialog.Show ' results is a boolean

MyResults = ActiveCell.Value

End Sub


I've never been able to figure out how to get the results from htis
dialog. It seems to only bring up a tool that the user can use but not
the VBA code.

The parameter are :
text, in_num, at_num, by_num, dir_num, match_case, match_byte

So you can use the following to find the string 123

Results = FindDialog.Show(arg1:="123")


--
joel
------------------------------------------------------------------------
joel's Profile: 229
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=163850

Microsoft Office Help

.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
"For each w in workbooks "can't find ".dat" open excel sheets, Ricky Excel Programming 1 October 23rd 09 06:00 AM
"Find" a wildcard as a place marker and "replace" with original va Eric Excel Discussion (Misc queries) 1 January 27th 09 07:00 PM
how to get vba to display excel 2002+ "Find & Replace" dialog [email protected] Excel Programming 4 October 23rd 07 05:01 PM
How to replace "#N/A" w "0"when vlookup couldn't find the match? Holly Excel Discussion (Misc queries) 2 July 17th 06 11:48 PM
Replace dialog should put focus on "Find What" not "Replace With" Michael Williams Excel Discussion (Misc queries) 0 May 24th 06 12:45 PM


All times are GMT +1. The time now is 02:07 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"