Free Microsoft Excel 2013 Quick Reference

VBA: excel as embedded object in word

Anybody out there know if it is possible to save a worksheet as an embedded object in a word doc automatically?

cheers

Lulu


Post your answer or comment

comments powered by Disqus
I am currently trying to get a macro which works fine in MS Excel to
work as an embeded object in MS Word. I have a feeling it has something

to do with the references. The refernces currently selected a

MS Excel 9.0 Object Library
MS Word 9.0 Object Library
OLE Automation
MS Office Object Library
Visual Basic for Applications
and Normal.

VBA gives the Compile Error: Method or Data Member not found

Any help is greatly appreciated
-Dwight

I am currently trying to get a macro which works fine in MS Excel to
work as an embeded object in MS Word. I have a feeling it has something

to do with the references. The refernces currently selected are:

MS Excel 9.0 Object Library
MS Word 9.0 Object Library
OLE Automation
MS Office Object Library
Visual Basic for Applications
and Normal.

VBA gives the Compile Error: Method or Data Member not found

Any help is greatly appreciated
-Dwight

I am currently trying to get a macro which works fine in MS Excel to
work as an embeded object in MS Word. I have a feeling it has something
to do with the references. The refernces currently selected are:

MS Excel 9.0 Object Library
MS Word 9.0 Object Library
OLE Automation
MS Office Object Library
Visual Basic for Applications
and Normal.

VBA gives the Compile Error: Method or Data Member not found

Any help is greatly appreciated
-Dwight

Embedded Excel objects in Word turning into a jpg problem; sometimes I embed an Excel object into a Word document, and it turns into a jpg. Anybody know a way to deal with this?

Hey all, I've searched high and low but cannot find an answer to this issue. I'll try to walk you through the steps.

1.) I open my excel document, in it I have a button that uses Application.GetOpenFilename to open a file, then paste the values into the actual excel document.
2.) I copy a set of data in excel to paste special into a Word document as a Microsoft Office Excel Worksheet Object.
3.) The data pastes ok into the Word document, then I click on the object, then right click > Format Object.
4.) Then I click on the Layout tab > Wrapping Style as Square, Align Right.
5.) An error pops up stating:

	VB:
	
 item cannot be found. 
Make sure the application Is properly installed, And that it has Not been deleted, moved, Or renamed. 

If you like these VB formatting tags please consider sponsoring the author in support of injured Royal Marines
So, from what I can gather after doing some research is that perhaps by using GetOpenFilename to paste values into my Excel document, it's causing issues with pasting it as an object within Word.

Another thing to note is that if I don't utilize the macro and just paste special into Excel by hand, I can copy/paste the excel data into Word and format the object with no issues.

Here is my macro for reference:


	VB:
	
 InputSpreads() 
    Dim wbSPREADS As Variant 
    Dim wsInstructions As Worksheet 
    Dim wb As Workbook 
    Dim ws1 As Worksheet 
    Dim ws2 As Worksheet 
    Dim N As Long 
    Dim FileName As String 
    Dim PathName As String 
     
    wbSPREADS = Application.GetOpenFilename(Title:="Locate the Spreads File") 
     
    If wbSPREADS = False Then 
         ' user cancelled
        Range("C3").Value = "Please Locate the Spreads File" 
        Exit Sub 
    End If 
     
    Set wsInstructions = ActiveWorkbook.Worksheets("Start Here") 
    Set ws1 = ActiveWorkbook.Worksheets("Balance Sheet") 
    Set ws2 = ActiveWorkbook.Worksheets("Income Statement") 
    Set wb = Workbooks.Open(wbSPREADS) 
     
    Application.ScreenUpdating = False 
    Application.Calculation = xlCalculationManual 
     
     
     
     
    If wb.Worksheets(2).Range("A3")  "ASSETS" Then 
         
        wsInstructions.Range("C3").Value = "Wrong file, try again!" 
         
        With wsInstructions.Range("C3").Interior 
            .ColorIndex = 3 
            .Pattern = xlSolid 
            .PatternColorIndex = xlAutomatic 
        End With 
        With wsInstructions.Range("C3").Font 
            .FontStyle = "Bold" 
        End With 
         
        Application.DisplayAlerts = False 
        wb.Close SaveChanges:=False 
        Application.DisplayAlerts = True 
        Exit Sub 
    End If 
     
    wb.Worksheets("BAL").Select 
    wb.Worksheets("BAL").Cells.Copy 
    ws1.Range("A1").PasteSpecial Paste:=xlPasteValues, _ 
    Operation:=xlNone, _ 
    SkipBlanks:=False, _ 
    Transpose:=False 
     
    wb.Worksheets("INC").Select 
    wb.Worksheets("INC").Cells.Copy 
    ws2.Range("A1").PasteSpecial Paste:=xlPasteValues, _ 
    Operation:=xlNone, _ 
    SkipBlanks:=False, _ 
    Transpose:=False 
     
    Application.DisplayAlerts = False 
    wb.Close SaveChanges:=False 
    Application.DisplayAlerts = True 
     
    wsInstructions.Select 
    N = InStrRev(wbSPREADS, "") 
    PathName = Left(wbSPREADS, N - 1) 
    FileName = Mid(wbSPREADS, N + 1) 
     
    Range("C3").Value = FileName 
     
    With wsInstructions.Range("C3").Interior 
        .ColorIndex = 4 
        .Pattern = xlSolid 
        .PatternColorIndex = xlAutomatic 
    End With 
    With wsInstructions.Range("C3").Font 
        .FontStyle = "Normal" 
    End With 
     
    Dim FlName As String 
     
    Application.Calculation = xlCalculationAutomatic 
    Application.ScreenUpdating = True 
     
End Sub 

If you like these VB formatting tags please consider sponsoring the author in support of injured Royal Marines
So, can anyone provide a hint as to if or why GetOpenFilename is causing this issue when pasting the object into Word?

Thanks

Hello Group.

I've embedded some excel cells into my report written in Word 2000. Is
there a way I can display the cell references next to the embedded object
in the printout.

For example if cells B10:C15 are the embedded cells, I want those who read
the printed document to see exactly which rows and which columns the
numbers belong to. Something like this:

B C
10 Jan 10%
11 Feb 15%
12 Mar 34%
13 Apr 14%
14 May 10%
15 Jun 12%

So when I say somthing like "The formula used here is C10/SUM(C10:C15)" my
readers would be able to refer to the embedded object and do the
calculations themselves if they wished.

Is this at all possible?

I will appreciate any information on this problem.

TC

draw on top of embedded object in Excel 2007

Is there a way to place a drawing object on top of an embedded object in Excel 2007?

Draw on top of embedded objects in Excel 2007

Is it possible to place a drawing object on top of an embedded object in Excel 2007?

All
I have a macro (.xla file) which i use in excel file. I have added this .xla through addin manager. The problem is it works fine as long as it is on one perticular PC. when i transfer it to another PC, it doesnt work. On another PC also i add this .xla in excel addin.
But still it doesnt work. As excel creates an file path (same i .xla path in my original PC) in the formula. when i remove that path then excel understands and search on its local addin. and it works
It is really a headache for me as i supplies this excel sheet along with .xla to many ppl. and everytime i need to do same.
Is there any way where i can add this .xla as a object in excel file itself. and whenever i send this file to anybody it should not creat any problem

Thanks in advance
suhas

Hello Group.

I've embedded some excel cells into my report written in Word 2000. Is
there a way I can display the cell references next to the embedded object
in the printout.

For example if cells B10:C15 are the embedded cells, I want those who read
the printed document to see exactly which rows and which columns the
numbers belong to. Something like this:

B C
10 Jan 10%
11 Feb 15%
12 Mar 34%
13 Apr 14%
14 May 10%
15 Jun 12%

So when I say somthing like "The formula used here is C10/SUM(C10:C15)" my
readers would be able to refer to the embedded object and do the
calculations themselves if they wished.

Is this at all possible?

I will appreciate any information on this problem.

TC

Hello,

I need to come up with a macro that will copy the contents of a cell and paste the cell contents into an embedded object within the worksheet.

I have already made reference to the embedded object in 'Tools' in VBA.

Thank you for your time.

I would like to be able to see an embedded object in an excel cell that is only visible on hover, similar to how the "insert comments" works.

Below is a screen short of what I would like to do and a conversation I had with another trader.

http://i44.tinypic.com/w5nb8.png

[13:35]<@BYF-L9S|ES> any excel experts in here?
[13:35]<@Stavros-L4C|ES|NQ> i'm highly proficient
[13:35]<@BYF-L9S|ES> let me get a screen shot for you
[13:35] <@BYF-L9S|ES> not sure if this can be done
[13:36] <@Stavros-L4C|ES|NQ> it typically can :_)
[13:41] <@BYF-L9S|ES> ok, hope it makes sense.
[13:41] <@BYF-L9S|ES> http://i44.tinypic.com/w5nb8.png
[13:42] <@Stavros-L4C|ES|NQ> oh ****, i don't think that's possible lol
[13:42] <@Stavros-L4C|ES|NQ> but a really cool idea
[13:42] <@Stavros-L4C|ES|NQ> submit it to MSFT
[13:43] <@Stavros-L4C|ES|NQ> i'd find that insanely useful
[13:43] <@Stavros-L4C|ES|NQ> embedded objects that are only visible on hover

Thank for the helop

How does Excel spell out numbers in words ?

Eg. I type in figures 1,500. It should appear as One Thousand Five Hundred.

Hello all,

I am new to programming and especially with Excel and VBA.

I hav a question.. Is it possible to use a VBA Macro as an Add-In. This program (Macro) will perform analyzes on data in one sheet and then export the result to another worksheet or new workbook itself.

Will it be possible this way to make the Excel files containing only data and all the Macros (program) not a part of it. When we will finish our analyzes the files can be circulated in our scientific community without any macros but containing only the input data and the analyzed output data. The output workbooks so obtained can also be uploaded to our database as we repeat the same procedure for lot of materials. So, we will have only excel sheets without any macros in it for circulation, discussion and in database.

Is it possible ?

thank you in advance for your kind help and please ignore my ignorance as I am a 'very' new user

regards
arora

Hello,

I have an Excel spreadsheet which contains companies (rows). These
companies have enough attributes to make the spreadsheet too wide to
print out. My idea was to put each company as a page in Word, for
example:

Company Address City State Zip Country Phone Number Fax
Number Contact Title
SomeCo SomeSt Ct ST 30000 US ###-###-#### ###-###-#### CFO

I'd like to show as:

Company SomeCo
Address SomeSt
City Ct
State ST
Zip 30000
Country US
Phone Number ###-###-####
Fax Number ###-###-####
Contact Title CFO

Any ideas?

Thanks!

Hi All,
I want to insert a single row of excel as an object in an email & want users to fill in & then they click on submit button.. all the data entered should be then automatically updated at backend in a database..may be MS access or even excel sheet would do...
I need to send out this excel as an object in an email to a DL which has more thn 800 recipients. so that whatevr they enter gets updated by itself.. n i do not have to spend time on copy pasting...

i hope am making sense... can somebody plz help me out... plz someone reply soon on this..evn a small step wud b appreciated as i need to this on coming monday...
Note: all users would be on the same internal network ... is there a solution to this??

All was well under Office 2003, however my VBA for 2010 doesn't seem to be working correctly. I've tried using the following code however when using option 1 it does paste as an embedded object but the formatting is all wrong. When using option 2 it comes out like i want it, embedded chart which you can right click and say edit data however this is a Linked document!! (i think this is new to word 2010, as it opens in separate excel document) 1) wrdDoc.FormFields("chart01").Range.PasteSpecial Link:=False, DataType:=wdPasteOLEObject, Placement:=wdInLine, DisplayAsIcon:=False Pastes embedded unlinked, but old format oleobject and formatting goes when editing in word 2) wrdApp.Selection.PasteSpecial Link:=False, DataType:=ppPasteDefault, Placement:=wdInLine, DisplayAsIcon:=False Pastes in word like i would like but it's linked! 3) Using just Range.Paste Pastes as a picture Any help would be kindly received! I can provide more code if it helps.

HI VBA Masters

I have a lil issue which i cannot overcome using vba, well i just dont know how to do it to be honest
Let me please explain the problem and i will be greatful for your kind support.

In the file attached there is a vba code that does brifly the following:
1. Filters one by one every unique record from col D.
2. Once a particular unique record is filtered it copies the whole lot incl headers and pastes it into a new workbook.
3. Saves it as "col D_col E_col B_col C, example: (0219918379_TR01_Malgorzata_Krawczyk) on my desktop in the folder called "Files".
4. Does that for every unique record in col D so the number of unique records will equal to the number of created excel files in the "Files" folder.

I really wish my vba could have an addtional skill but i am not sure this is possible.

1.If possible before saving as, as described above i wish there was an embedded object inserted in the same sheet. (example Sheet2)
2.The backup file's name would be stated in column F (backup name) for every transnumber in column D
3.The backup files would be stored on my desktop in the "backup" folder
4.VBA would embed an object in the following way: Insert -> Object -> tab: "create from file" -> browse (Desktop -> backup) -> Display as icon -> Ok
5.The backup files may have different extensions like xls, xlsx or msg

in short words: before saving as vba checks what is the backup file name for a particular transnumber. Finds it in the "backup" folder and inserts
Not sure if this is possible.
Many thanks in advance for your kind support
Regards
Peter

Hi,

I'm trying to modify several Excel objects in word. I need to open
every Excel object (one at time) and after that I need to find and
replace a text in it, save changes and return to word to go the next
until the last Excel object has been changed.

Unfortunately I have done it manually but I couldn't do using VBA and
there are 110 files waiting for this process.

I'd apreciate if any of you can give me an idea.

Thanks,

Sandra

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

I'm building an Office Application with Excel part of the application. This
is all being done using Office 2000 Professional running under XP Pro (SP2)

I have embedded several Excel tables and associated graphs in a Word
document. I have done this using VBA, sucking in the tables and graphs from
Excel, to bookmarked locations in Word. All works fine except that I have
these surplus table rows appended after each graph in Word, causing
unnecessary page breaks in Word, which then have 2B manually deleted.

I have assigned each table and graph combination a range named in Excel. The
range extends over the table and the graph completely. Does anyone know of a
"clean" way to pluck out Excel tables and graphs for embedding into Word
without all those surplus table rows? eg. Is it possible to just plug the
graph into Word from Excel using VBA?

--

Richard John
rjbpond@bigpond.net.au

I've seen a few posts about issues copying worksheets containing cells with
text values > 255 characters. I have a similar issue but it involved copying
a cell range from Excel and using Paste Special to paste them as an embedded
workbook in Word.

If I copy the cell range from one Excel worksheet and paste them to another
worksheet the cell contents are not truncated. However, when I paste special
into Word as an embedded workbook, the cell contents are truncated.

Is there a way to get the Excel cell range into an embeeded workbook in Word
(or PowerPoint) without having the text truncated?

- Drew

I have a template MS Word Document that has approximately 65 embedded Excel worksheets. Each worksheet performs a VLOOKUP to evaluate specific conditions based on a risk and threat matrix. Each worksheet is a unique sheet that is relative only to the proceeding paragraph. The last visible field calculates a composite score based on the average of all VLOOKUP results.

I would like to be able to have a final worksheet at the end of the document that calculates the total number of each grading criteria as a summary. I am having great difficulty in referencing values from one embedded worksheet to another.

Specifically – If an embedded worksheet contains a cell value, how is it possible to reference that cell value in another embedded worksheet in the same document?

I had hoped not to have a Word Document and an Excel document, but simply a Word document. This is because this report will go through multiple “Hands” during its critique and revision. I need the functionality of sending only a single “All inclusive document”

If I have chosen an improper method to accomplish this process, please inform me of that as well.

Many thanks,

Jared

I have created a summation table in excel. Have linked it to word. It(object
in word) automatically updates the sum when I change it in excel; however, it
will not update the sum if I change the cells that should change the sum cell
in word. I have followed instuctions for manual update and by double clicking
in the excel object in word but it will not automatically update the sum cell.

Hi ,
I inserted a "microsoft word document" object into an excel sheet. But if
the content of the document is more than two pages , it seems that it can't
be shown wholely in the "microsoft word document" object. How can I browse a
multi-pages "microsoft word document" object in Excel 2003 just like in Word
2003?
Any thoughts would be greatly appreciated. Thanks.

Best regards,

dapanpan


No luck finding an answer? You could always try Google.