[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

VBA error: Cannot create Inet1 object?

Posted on 2004-04-04
8
Medium Priority
?
2,717 Views
Last Modified: 2012-06-27
Running the macro below in PowerPoint 2002 produces the error:

Error 429: "Activex component cannot create object"

on this line: Set Inet1 = CreateObject("InetCtls.Inet")

I have referenced Microsoft Internet Controls (tools > references > ).

Could someone please suggest possible corrections?

Please be aware that I am a total VBA newbie trying to build this by copying examples.

Sub WebUpdate()

    Dim Inet1 As Object
    Set Inet1 = CreateObject("InetCtls.Inet")
    Dim txtURLSource As String
    txtURLSource = Inet1.OpenUrl("http://www.mydomain.com/a_file.htm")

-- do some stuff with the data here --

End Sub
0
Comment
Question by:xfvgdrthbdtyvhgscv
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 10752860
Change:
Set Inet1 = CreateObject("InetCtls.Inet")
To:
Set Inet1 = CreateObject("InetCtlsObjects.Inet")
0
 
LVL 1

Author Comment

by:xfvgdrthbdtyvhgscv
ID: 10752923
Thanks for the suggestion, ac, but still get the same error on that line.  

I'm open to other suggestions if you have them!

0
 
LVL 15

Expert Comment

by:unknown_routine
ID: 10753005
the syntax your using is correct.

I  don't see any problem in your code. I tested it on powerpoint 2000 worked fine.


I may be a powerpoint 2002 issue(very unlikely)

As the 1st step  do these things:


1: if you have word2000 or power point 2000 copy paste your code there to see if it works.

2: if you have Visual basic , test your code inside VB to see if it works.

0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 17

Expert Comment

by:zzzzzooc
ID: 10753145
You might not have the class registered (or correctly registered) for use in CreateObject.

Open up Regedit (Start -> Run -> "regedit" (press enter)) and check for...

HKEY_CLASSES_ROOT\InetCtls.Inet

It should have subkeys of CLSID and CurVer. The CLSID for me is "{48E59293-9880-11CF-9754-00AA00C00908}" and the CurVer is "InetCtls.Inet.1" which is another key in HKEY_CLASSES_ROOT that may have to exist (not sure).
0
 
LVL 1

Author Comment

by:xfvgdrthbdtyvhgscv
ID: 10753324
Thanks again.

My objective here is to get some data from a cgi-script and update a chart in a slide.  I have another macro that opens an IE window and calls the script.  I could have the script output the needed data in form elements or javascript variables that I can then access fromVB.  But I had wanted to avoid this just for the sake of elegance.

Frankly, though, the more I read about using Inet, the less I'm tempted by elegance.  I see tons of potential pitfalls for my code to fail, considering that the final PPT file is intended to be downloaded by any of a thousand users whose PC's and their installed Office might have any number of configurations.

So I'm increasingly leaning today towards the IE window solution.

Anyone care to contradict / confirm this plan?

Thanks again.
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 11441165
PAQed, with points refunded (500)

modulo
Community Support Moderator
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question