"I have created a complex spreadsheet.......
......
Can anyone point me in the right direction...."




















Right Direction : Don't Create complex worksheet, keep life simple  :-)



Regards,    Anil Bhange
IP Phone - 512320 | Mobile - 90290 32123

-----Original Message-----
From: excel-macros@googlegroups.com [mailto:excel-macros@googlegroups.com] On 
Behalf Of BJthebear
Sent: Saturday, February 05, 2011 8:05 PM
To: MS EXCEL AND VBA MACROS
Subject: $$Excel-Macros$$ Copying userform to new worksheet - Excel 2003

I have created a complex spreadsheet that extracts certain worksheets and 
modules and creates another workbook which is subsequently emailed using 
Outlook to a list of individuals.  It is not a complete copy of the original 
workbook as there is information which must not be sent out.

However I have been experimenting with using an input userform which works 
great on the original worksheet but I cannot fathom out how to send a copy of 
the userform together with the userform coding across to the created worksheet 
which is to be emailed.


I found out how to send the module across using the following VBA
coding:-

 '   export module1 to file ready to be imported into copy of
spreadsheet

    With ActiveWorkbook
        FName = .Path & "\exportmodule.bas"
        .VBProject.VBComponents("Module1").Export FName
    End With

' move to new copy of spreadsheet
   Set Destwb = ActiveWorkbook

 'import Module 1 to new worksheet
    ActiveWorkbook.VBProject.VBComponents.Import FName


Can anyone point me in the right direction for copying the userform across 
using VBA

Brian Jermain
Scotland

--
----------------------------------------------------------------------------------
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

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link 
http://www.facebook.com/discussexcel

-- 
----------------------------------------------------------------------------------
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

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel

Reply via email to