oleobjects

  1. S

    Import a pdf as image in Excel using vba

    Hi everyone. Iam using this code trying to add pdf in my sheet.My problem is that appears only the first page.Any ideas how to appear every page in pdf? Thanks in advance Sub insert_pdf_to_report() Dim ol As OLEObject Dim p As Page Set ol = ActiveSheet.OLEObjects.Add(...
  2. C

    Embedding the Excel File in a Word Report

    Hi, I am creating a report creation Macro to Export data to word but would also like to automatically embed the Excel file that the Macro is running from into the word template. Hi have been experimenting with this code but not sure if it is the correct way to do it. Getfile =...
  3. M

    Printout in a loop, keep getting same

    Hi,I have used below code to fill certain OLEObjects in a loop:Dim rng As RangeDim wsS As WorksheetDim wsD As WorksheetActiveSheet.Copy after:=Sheets(Sheets.Count)Sheets(Sheets.Count).Name = "Sourcebook"Set wsS = Sheets("Sourcebook")Set wsD = Sheets("CMR")Set rng = wsS.Range("A3"...
  4. P

    OLEObject Update LinkedCell witch VBA Code for a Check-Box

    Hi, I have this code which creates an ActiveX Check-Box with vba: With .OLEObjects.Add(ClassType:="Forms.CheckBox.1", Link:=False, DisplayAsIcon:=False, _ Left:=30, _ Top:=30, _ Width:=20, _ Height:=5) .Name =...
  5. J

    Close embedded Excel Object in VBA

    Hello, I'm going crazy trying to figure this out. I have, for security reasons, placed an embedded excel object (as an icon) in a very hidden sheet. Various code pulls up the object, extracts or adds data, and closes it with screen updates off. The code below works perfectly in Excel 2013, but...
  6. J

    Iterate Through OLEObjects For i

    I want to iterate through a range of combo boxes with similar names and add items to the combo box. For i = 1 To 5 Set varComoBox = ThisWorkbook.Worksheets("System").OLEObjects("cbo" & i) With varComoBox & i .AddItem ">" .AddItem ">=" .AddItem "<" .AddItem "<=" .AddItem "=" End With Next I...
  7. bs0d

    OLEObjects sub called when change in value?

    I have a checkbox with a _click() subroutine. I also have a command button to effectively reset my form. In this, I set the value of the checkbox to false (unchecked). When I do so, it executes the _click() subroutine. I tried changing _click() to _change() and it still does the same thing...
  8. W

    ListBox embedded in Frame of OLEobject on worksheet - where is the ListBox Click_Event?

    I have a worksheet to which I add an OLEobject as an MSForms Frame. I then add an MSForms listbox inside the frame contained in the OLEObject.Object property. I want to be able to trigger a click event when the user selects an item from the listbox inside the frame. I can trigger the...
  9. J

    Attach documents in Excel and then view them.

    I have an Excel workbook that allows users to attach documents. Once attached, I need an option to view/open these documents. I need to get the name of the open document so I can continue to control via the Excel workbook. Any ideas? Below is the full code for the View sub. I get "Run-time...
  10. M

    OLEObjects will not work with grouped controls?

    Hi Everybody. I am trying to set all checkboxes and radio buttons on a spreadsheet to False every time a drop down list value changes and I am using the following code: Dim ole As OLEObject For Each ole In ActiveSheet.OLEObjects If ole.progID = "Forms.CheckBox.1" Or ole.progID =...
  11. I

    Creating CheckBoxes with VBA results in random order

    I have some VBA (using Excel 2007) that deletes and re-creates a bunch (20-ish) checkboxes in a spreadsheet. Since i'm using the controls-based checkboxes, Excel defaults them to object names of "CheckBox1, CheckBox2, CheckBox3, etc" as I create them the first time around. Later on, i clear...
  12. D

    Add Optionbutton with VBA question

    Hello everyone, I am new to the Mr. Excel message boards. I found them after watching his Livelessons video training series. I've searched the boards, msdn, excel help, books, pdf's, etc and now I turn to the knowledge here on these boards for some help & guidance with the following situaiton...
  13. J

    Checkboxes disappear after macro is run

    Hi I have a macro that loops through a bunch of checkboxes to see if they are checked or not. If they are not checked the row it sits on plus the row below is hidden. Also the unchecked checkbox is also hidden. After this I call on print preview. Sub print_checked() Dim obj As OLEObject...
  14. E

    Delete OLEObjects in Break Mode

    Hi, I am writing some code that will create random data which will be used in a specific sheet to calculate certain values using the cell formulas. This sheet will be copied as many times as necessary to input the numbers generated (The code will generate a different set of numbers for a...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top