473,386 Members | 1,699 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

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 3593

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.infovis.co.uk> wrote in message
news:Jo**@nospam.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 interoperability .. 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.infovis.co.uk> wrote in message
news:Jo**@nospam.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*******@gmail.com> wrote in message
news:On**************@TK2MSFTNGP10.phx.gbl...
I 've built a big project on .net excel interoperability .. 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.infovis.co.uk> wrote in message
news:Jo**@nospam.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*******@gmail.com> wrote in message
news:On**************@TK2MSFTNGP10.phx.gbl...
I 've built a big project on .net excel interoperability .. 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.infovis.co.uk> wrote in message
news:Jo**@nospam.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
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...
0
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...
4
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)....
1
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...
2
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,...
1
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...
2
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...
1
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...
1
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...
3
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 ...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
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...

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.