473,898 Members | 2,507 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

office interop

Hi

I need to call methods from office apps from my vb.net app. Some of my
clients are still on office 2000 so to maintain compatibility I can not use
office 2003 PIA. Can I avoid the whole PIA route by using late binding?
Could someone please give me an example of using late binding for calling
office apps?

Thanks

Regards
Nov 21 '05 #1
5 3630

John,

You will still need the library from Office 2000. Yes they are backward
compatible. That is not true in all cases however. It is a pain but I
maintain all office installations on my machine in order to accommodate
these situations and for testing purposes because I want to be using the
bottom most library I know will be used by the client otherwise you run
the risk or writing incompatible code.

"John" <Jo**@nospam.in fovis.co.uk> wrote in message
news:Jo**@nospa m.infovis.co.uk :
Hi

I need to call methods from office apps from my vb.net app. Some of my
clients are still on office 2000 so to maintain compatibility I can not
use
office 2003 PIA. Can I avoid the whole PIA route by using late binding?
Could someone please give me an example of using late binding for calling

office apps?

Thanks

Regards


Nov 21 '05 #2
Hi John!

"John" schrieb
I need to call methods from office apps from my vb.net app. Some of my
clients are still on office 2000 so to maintain compatibility I can not
use office 2003 PIA. Can I avoid the whole PIA route by using late
binding? Could someone please give me an example of using late binding for
calling office apps?


Here is a small late-binding example:

How To Use Visual Basic .NET for Binding for Office Automation Servers
http://support.microsoft.com/kb/304661/EN-US/

Cheers

Arne Janning
Nov 21 '05 #3
I 've built a big project on .net excel interoperabilit y .. but i'm
struck bcoz i've to use that application with differenrt version of
applications. Can u Suggest any idea how can i change my excel com
wrapper on the runtime .. or with any other way which i can deploy the
system with respective excel com .

I'm having problem which compliing also as excel 2000 takes some less
arguments than excel 2002 , open and save functions ..
scorpion53061 wrote:

John,

You will still need the library from Office 2000. Yes they are backward
compatible. That is not true in all cases however. It is a pain but I
maintain all office installations on my machine in order to accommodate
these situations and for testing purposes because I want to be using the
bottom most library I know will be used by the client otherwise you run
the risk or writing incompatible code.

"John" <Jo**@nospam.in fovis.co.uk> wrote in message
news:Jo**@nospa m.infovis.co.uk :
Hi

I need to call methods from office apps from my vb.net app. Some of my
clients are still on office 2000 so to maintain compatibility I can not
use
office 2003 PIA. Can I avoid the whole PIA route by using late binding?
Could someone please give me an example of using late binding for calling

office apps?

Thanks

Regards


Nov 21 '05 #4
Hi Dhyan

I have not yet tried this but I was told to use late binding. This way you
do not need the interop dlls and hence no tying down to any particular
version at design time. Secondly at runtime call the function with one set
of arguments. If there is an error, trap the error and call the function
with the alternate arguments. Not elegant but it may work. If it does let us
all know.

Regards
"dhyan" <dh*******@gmai l.com> wrote in message
news:On******** ******@TK2MSFTN GP10.phx.gbl...
I 've built a big project on .net excel interoperabilit y .. but i'm struck
bcoz i've to use that application with differenrt version of applications.
Can u Suggest any idea how can i change my excel com wrapper on the
runtime .. or with any other way which i can deploy the system with
respective excel com .

I'm having problem which compliing also as excel 2000 takes some less
arguments than excel 2002 , open and save functions ..
scorpion53061 wrote:

John,

You will still need the library from Office 2000. Yes they are backward
compatible. That is not true in all cases however. It is a pain but I
maintain all office installations on my machine in order to accommodate
these situations and for testing purposes because I want to be using the
bottom most library I know will be used by the client otherwise you run
the risk or writing incompatible code.

"John" <Jo**@nospam.in fovis.co.uk> wrote in message
news:Jo**@nospa m.infovis.co.uk :
Hi

I need to call methods from office apps from my vb.net app. Some of my
clients are still on office 2000 so to maintain compatibility I can not
use
office 2003 PIA. Can I avoid the whole PIA route by using late binding?
Could someone please give me an example of using late binding for
calling

office apps?

Thanks

Regards


Nov 21 '05 #5

You can achieve multiple-version compatibility without resorting to late
binding.
It requires that you build an Interop assembly against the lowest version:
http://www.devcity.net/Articles/163/1/article.aspx

--scott

--

"John" wrote:
Hi Dhyan

I have not yet tried this but I was told to use late binding. This way you
do not need the interop dlls and hence no tying down to any particular
version at design time. Secondly at runtime call the function with one set
of arguments. If there is an error, trap the error and call the function
with the alternate arguments. Not elegant but it may work. If it does let us
all know.

Regards
"dhyan" <dh*******@gmai l.com> wrote in message
news:On******** ******@TK2MSFTN GP10.phx.gbl...
I 've built a big project on .net excel interoperabilit y .. but i'm struck
bcoz i've to use that application with differenrt version of applications.
Can u Suggest any idea how can i change my excel com wrapper on the
runtime .. or with any other way which i can deploy the system with
respective excel com .

I'm having problem which compliing also as excel 2000 takes some less
arguments than excel 2002 , open and save functions ..
scorpion53061 wrote:

John,

You will still need the library from Office 2000. Yes they are backward
compatible. That is not true in all cases however. It is a pain but I
maintain all office installations on my machine in order to accommodate
these situations and for testing purposes because I want to be using the
bottom most library I know will be used by the client otherwise you run
the risk or writing incompatible code.

"John" <Jo**@nospam.in fovis.co.uk> wrote in message
news:Jo**@nospa m.infovis.co.uk :

Hi

I need to call methods from office apps from my vb.net app. Some of my
clients are still on office 2000 so to maintain compatibility I can not
use
office 2003 PIA. Can I avoid the whole PIA route by using late binding?
Could someone please give me an example of using late binding for
calling

office apps?

Thanks

Regards


Nov 21 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2587
by: Bob N5 | last post by:
I am working on an application that uses interop to do some simple operations with both Excel and Word. I have most of functionality working, but ran into issues on making things work with both versions of office. My questions are: 1. What is the 'best' practice for building an application that will work with both versions of office? Do I need to have a separate build with different references for each? 2. Can I install interop...
0
5583
by: AllenF | last post by:
I have a library (named DSG) created in C# which other programs use to build Excel spreadsheeets. This library uses the office PIAs "Microsoft.Office.Interop.Excel.dll" and also references the Microsoft Office v10 library using ActiveX. Recently I loaded Microsoft's Project 2003 (v11) to my programming computer for tracking purposes, which loaded the Microsoft Office v11 library. Now, when I run my programs (in VS C#) I get two errors:...
4
4084
by: J-T | last post by:
I'm trying to read an excell file in my .Net application using Office XP Primary Interop Assemblies (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnoxpta/html/odc_oxppias.asp). I have installed Office 2003 on my developemnt box.Will my application be able to read all kinds of Excell file (97-2000-2003)? Dose the wrapper that .Net framework generates backward copatiable? Do I have to have the same version of Office...
1
6938
by: Stephen Noronha | last post by:
Hi, I am trying a sample app to send an email from my app I am getting a "type not defined error" I have added "Office and Outlook" COM component but still I am getting this error... Please advice, Stephen
2
11499
by: William LaMartin | last post by:
I have created a program that allows for the automation of things in Word documents, like changing the values of DocVariables and the links to Excel Sheets. I did it using interoperoperatability, where, after adding a reference to Microsoft.Office.Core and a reference to Microsoft Word I declare objects as follows: Dim oWordApp As New Microsoft.Office.Interop.Word.Application, . Everything works fine on the development computer...
1
5517
by: BK | last post by:
I have a .NET Solution (currently in 2003, FW 1.1) that uses Office automation for a few things (generates a Word document, dumps datagrids to Excel, etc.). One of my programmers works on the project from time to time. We always have problems when he loads up the latest version of the Solution however, and it appears to be a compatibility issue with difference in Office versions. My development platform is Xp Professional running...
2
7312
by: JC | last post by:
Anybody knows what problem has this code? I think, in the Garbage Collector? You know the Solution? The program in the test's case, whit 350 contacts, run OK before number 86. The error is a "Array index out of bounds". Microsoft.Office.Interop.Outlook._Application olApp = new Microsoft.Office.Interop.Outlook.ApplicationClass(); Microsoft.Office.Interop.Outlook._NameSpace olNs = olApp.GetNamespace("MAPI");
1
3234
by: =?Utf-8?B?cm9i?= | last post by:
C#.Net Outlook 2003 automation (programmatically) with Office.Interop.Outlook Problem: I have my outlook 2003 configured with multiple mailbox on my local machine. I want to specify the mailbox and server (Exchange server mail box) to connect and then save the mailitems(from Inbox or any other folder) based on a filter to a*.msg file. I want to achieve this using only one Interop dll if this is possible. Tried so far:
1
2876
by: allbelonging | last post by:
C#.Net Outlook 2003 automation (programmatically) with Office.Interop.Outlook Problem: I have my outlook 2003 configured with multiple mailbox on my local machine. I want to specify the mailbox and server (Exchange server mail box) to connect and then save the mailitems(from Inbox or any other folder) based on a filter to a*.msg file. I want to achieve this using only one Interop dll if this is possible. Tried so far:
3
11660
OuTCasT
by: OuTCasT | last post by:
Hi I have created an asp.net project that exports items from datagridview to and outlook calendar This is the code that i have used.. Dim body As String Dim ends As String Dim location As String Dim start As String Dim subject As String
0
9839
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10854
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10946
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9658
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
8034
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5876
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
6076
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
4295
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3303
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.