ASP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingASP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old September 4th, 2003, 01:48 PM
kshri kshri is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 3 kshri User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Problem distributing ActiveX control

I have an ActiveX control (.ocx) that have packaged using P&D wizard into a .CAB file. This is called in an ASP page using CLASSID and CODEBASE tags. This runs successfully on the machine that I used to develop this control. However, when another I launch my Web app from another PC, it starts downloading the .CAB file, and at the end it terminates with "Object doesn't support this method or property" error. Subsequently, when I check the registry on that machine, it does not show any entries for the new ocx. What could be the problem? Could it be that some of the dependent files are missing? Also, I have both Visual Studio 6 and Visual Studio .Net installed on my development PC.

Appreciate any inputs. Thanks in advance.

Reply With Quote
  #2  
Old September 4th, 2003, 02:49 PM
admcdona admcdona is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Posts: 20 admcdona User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Do you have any script on the ASP page that is calling any of your OCX's methods? If so...you may be making the call incorrectly.

Are you calling/using any other objects in your OCX's UserControl_Initialize sub?

Reply With Quote
  #3  
Old September 4th, 2003, 02:59 PM
kshri kshri is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 3 kshri User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
I am calling a Public Sub called Initialize_Control (this was created by me in the General section) in the ASP's VBscript as follows:

MyControl.Initialize_Control.

I know that this is existing and being called correctly.

I do not have anything in UserControl_Initialize sub.

Somebody suggested that I register this .ocx manually by copying the file over to the client machine I am trying to test this on...You user regsvr32 for that, right? Do you think that will work?

Thx.

Reply With Quote
  #4  
Old September 4th, 2003, 06:22 PM
admcdona admcdona is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Posts: 20 admcdona User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
If you can install the OCX on the clients machine manually (using regsvr32) that's one option. The only problem with that is if you make a new version of the OCX, you'll have to break compatability and install manually again or you'll have to manually uninstall the old and install the new. So if you see future versions down the line...I'd highly suggest taking the time to get the .CAB deployment working.

Before you go this route...let me just suggest that you double check your <OBJECT> tag. Specifically your CLASSID. Since you say the component downloads, the codebase must be correct...so not being able to use the object after the download could possibly be caused by a bad CLASSID.

The only other thing I can possibly think of is if your Initialize_Control sub is trying to create/use an object that either a) you didn't include in your package or b) you have one version of the object on your machine, and your client has a different (likely older) version on their machine.

Reply With Quote
  #5  
Old September 5th, 2003, 09:00 AM
kshri kshri is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 3 kshri User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Having different versions of included files is quite possible since I also have VS.NET installed on my development machine. One thing I was thinking was not to include any of the supporting DLLs/OCXs since they are already available on the client machine (this is so since there are other controls that share almost same files). This way I could avoid any version conflicts. But you are right, I need to get the .CAB thing working. Manual registration is not a practical solution.

Lemme ask you this...doesn't IE not download and register existing files if there are already present on the client? For instance if my control called say Mytest.ocx requires 1.DLL, 2.DLL, and 3.ocx. Imagine 1.DLL, 2.DLL, and 3.ocx are all already present on client machine. I make changes to Mytest.ocx, and package all four files into a new .CAB file. Now lets say my 1.DLL (say one of Microsoft DLLs) is of different version than what the client already has. Shouldn't IE ignore 1.DLL, 2.DLL and 3.ocx while downloading the .CAB file? Wouldn't manually registering just Mytest.ocx and having it working essentially mean that those files are really redundant. Your insights.

Reply With Quote
  #6  
Old September 5th, 2003, 10:00 AM
admcdona admcdona is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2003
Posts: 20 admcdona User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
IE doesn't even know what files are included in your .CAB. IE bases it's decision to download the .CAB entirely on the version # of the .CAB itself (as opposed to the versions of the files within the .CAB). Once it is downloaded it automatically installs all new .dll and .ocx files. If a file already exists on your clients computer, it checks what version they have. If they have an older version, the file from your .CAB IS installed. If your .CAB contains an older version, your file is ignored.

If you are sure that the client computer already has the other files that your ocx needs, then I would definitely exclude those files from the .CAB. I do this mostly to reduce the download times for my clients. I would say 90 - 95% of my .CABs contain just my .ocx.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingASP Development > Problem distributing ActiveX control


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump




 Free IT White Papers!
 
Create the Optimal Architecture for your Critical Applications
Warburton's the largest independently owned bakery in the UK faced a number of difficult challenges in providing the most robust yet efficient IT infrastructure for their organization's success. IBM's services combined with their xSeries servers created the perfect platform for their SAP environment with sufficient flexibility, and did so in very time effective fashion.

Request Your Free Technology Downloads!
 
Five Best Practices for Deploying a Successful Service-Oriented Architecture
This white paper describes the benefits you can expect with SOA, and how IBM can help take your business there.

Request Your Free Technology Downloads!
 
Gartner Magic Quadrant for Application Delivery Controllers
Gartner summarizes its view on Application Delivery Controllers, evaluates strengths and weaknesses of solutions, and provides Magic Quadrant reporting for a quick comparison across all vendors. Learn from Gartner how you can benefit from an all-in-one device like Citrix NetScaler that delivers the highest levels of availability, performance and security.

Request Your Free Technology Downloads!
 
Knowledge is Power
What you don't know can hurt you, and is likely costing you money and increasing your security risks during an era of scarce resources. This white paper proposes six key strategies that enterprise security managers can use to improve their network defense posture.

Request Your Free Technology Downloads!
 
Rationalizing the Multi-Tool Environment
The rationalized multi-tool approach is flexible, scalable and cost effective. It provides the necessary input to the IT service management business processes. It preserves prior investments in monitoring tools, empowers technologists to select the best tools with which to do their jobs, and enhances effective response to incidents.

Request Your Free Technology Downloads!
 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 




© 2003-2010 by Developer Shed. All rights reserved. DS Cluster 9 Hosted by Hostway
For more Enterprise Application Development news, visit eWeek