Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB.NET 1.0 > VB.NET 2002/2003 Basics
|
VB.NET 2002/2003 Basics For coders who are new to Visual Basic, working in .NET versions 2002 or 2003 (1.0 and 1.1).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET 2002/2003 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 28th, 2004, 08:52 AM
Authorized User
 
Join Date: Sep 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Converting VBA Excel to VB.Net. Help help.

Hi there,

I am just so frustrated now. I have been trying now for a month to control excel from VB.Net. However I cannot get the neccessary methods i want to run into vb.net.

For example, I can record a macro in excel and I understand the VBA script. But I cannot seem to even use it in VB.net.

I understand that I have to add the COM reference and i have done all that.

I really need a book or a website which is able to teach me some VB.net which can allow me to understand the interaction between VB.Net and Excel alot better. Perhaps even a list of commands which i can use. Right now it is just trial and error, taking up loads and loads of time.

I have found a article on the microsoft site saying that i can add VBA macros into excel and run it. But i am sure VB.net is powerful enough to control excel.....

If you could direct me to a book/source of information. I would be most most Grateful !

THANKS !

 
Old September 28th, 2004, 11:14 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,101
Thanks: 0
Thanked 2 Times in 2 Posts
Default

You can't do what your trying to do. You have wasted a month.

"converting" a recorded macro is just not going to work. You will need to write this in vb.net. The macro language of VBA isn't compatible with VB.NET.


EDIT: you should keep in mind that Excel, like all of MS Office, are *NOT* made to be automated against (well, Office 2003 can do it). Using an older version this way is asking for difficulty. Make sure you are doing it on a machine with O2k3

Hal Levy
I am here to help you, not do it for you.
 
Old September 28th, 2004, 11:16 AM
Authorized User
 
Join Date: Sep 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I know it isn't compatible,

But i cannot find the equivalent function of what i want to do in excel using VB.Net.

 
Old September 28th, 2004, 11:38 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,101
Thanks: 0
Thanked 2 Times in 2 Posts
Default

And what function do you want to do in excel?


Hal Levy
I am here to help you, not do it for you.
 
Old October 5th, 2004, 04:58 PM
Registered User
 
Join Date: Oct 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to tankd4life77 Send a message via Yahoo to tankd4life77
Default

I have office 2003, I want to be able to open an excel document. I was able to open excel through the snippet you posted. I also checked out the website that was listed in this forum listing, but had no luck with my problem. Please help as much as you can.

Thank you,
tankd






Similar Threads
Thread Thread Starter Forum Replies Last Post
Calling VB.Net Dll from Excel VBA zyphax Pro VB.NET 2002/2003 4 July 16th, 2007 08:41 PM
Converting C# to VB.net ninel General .NET 0 August 11th, 2006 12:36 PM
Converting excel data to Access using excel VBA ShaileshShinde VB Databases Basics 1 April 26th, 2006 07:57 AM
Converting Excel formulae to VB James Diamond Excel VBA 3 May 11th, 2004 06:23 AM
converting DTS package from VB 6 to VB .NET petroleo Pro VB Databases 0 August 18th, 2003 05:01 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.