Thanks a bundle Dave. This has expedited my work even more..... :-) (P.S) Can anyone refer me to a good course from where I can learn to write macros.......
On Wed, Apr 21, 2010 at 4:31 AM, Dave Bonallack <davebonall...@hotmail.com>wrote: > Hi Zac, > Can I suggest a simpler approach? > Using the Ctrl key, select the 2 cells you want to swap, then use a > shortcut key to run this code: > > Sub swap() > If Selection.Count <> 2 Then Exit Sub > A = ActiveCell.Value > B = ActiveCell.Address > For Each c In Selection > c.Select > Exit For > Next c > D = ActiveCell.Value > ActiveCell.Value = A > Range(B).Value = D > End Sub > > It should be quicker than a dialogue box with 3 questions. > > Regards - Dave. > > ------------------------------ > Date: Tue, 20 Apr 2010 14:55:44 +0300 > Subject: $$Excel-Macros$$ Urgent Help Required in a macro > From: chaudhry.zahid....@gmail.com > To: excel-macros@googlegroups.com > > > Hi Group, > > I'm working in a huge excel sheet with thousands of entries. I am currently > looking for a macro, that when invoked (upon press of a key etc) would open > a dialogue box having three fields. The first field being Select Row, In > which I can write a row number Like 3, the second filed would contain > "Replace item from column", where I can write, for example G, and the third > field containing an other "Replace item from column" for example AA. In this > case the VBA code should select cells G3 and AA3. Than when I press enter or > a button on the excel sheet the contents of cell G3 should go to AA3 and > contents of AA3 should go to G3. The dialogue should not close after the > cell contents have been replaced, but should close upon clicking the cross > because there would be mutiple entries that need correction. > > An urgent reply and help would be highly appriciated, I have very little > time to do tjis HUGE task of finding and replacing data in excel. > > Thanks in advance and Regards, > > ZAC. > > -- > > ---------------------------------------------------------------------------------- > Some important links for excel users: > 1. Follow us on TWITTER for tips tricks and links : > http://twitter.com/exceldailytip > 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 > 3. Excel tutorials at http://www.excel-macros.blogspot.com > 4. Learn VBA Macros at http://www.quickvba.blogspot.com > 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com > > To post to this group, send email to excel-macros@googlegroups.com > > <><><><><><><><><><><><><><><><><><><><><><> > HELP US GROW !! > > We reach over 6,800 subscribers worldwide and receive many nice notes about > the learning and support from the group.Let friends and co-workers know they > can subscribe to group at > http://groups.google.com/group/excel-macros/subscribe > > ------------------------------ > Find it on Domain.com.au <http://domain.com.au/> Need a new place to > live?<http://clk.atdmt.com/NMN/go/157631292/direct/01/> > > -- > > ---------------------------------------------------------------------------------- > Some important links for excel users: > 1. Follow us on TWITTER for tips tricks and links : > http://twitter.com/exceldailytip > 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 > 3. Excel tutorials at http://www.excel-macros.blogspot.com > 4. Learn VBA Macros at http://www.quickvba.blogspot.com > 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com > > To post to this group, send email to excel-macros@googlegroups.com > > <><><><><><><><><><><><><><><><><><><><><><> > HELP US GROW !! > > We reach over 6,800 subscribers worldwide and receive many nice notes about > the learning and support from the group.Let friends and co-workers know they > can subscribe to group at > http://groups.google.com/group/excel-macros/subscribe > -- ---------------------------------------------------------------------------------- Some important links for excel users: 1. Follow us on TWITTER for tips tricks and links : http://twitter.com/exceldailytip 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 3. Excel tutorials at http://www.excel-macros.blogspot.com 4. Learn VBA Macros at http://www.quickvba.blogspot.com 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com <><><><><><><><><><><><><><><><><><><><><><> HELP US GROW !! We reach over 6,800 subscribers worldwide and receive many nice notes about the learning and support from the group.Let friends and co-workers know they can subscribe to group at http://groups.google.com/group/excel-macros/subscribe