How to Print Excel File In VB.Net???

hi,

I have a function for creating an excel report:

PseudoCode:

Loop1

       Read through the dabase; Can Have several Records; Each Record is 1 file    

       Loop2

              MyBase.BookOpen("C:\Documents and Settings\sheila\My Documents\Visual Studio 2005\Projects\excel1\Format.xls")
               1 file---->can have several pages

               MyBase.BookSaveAs("C:\Documents and Settings\sheila\Sample Excel Files\" & filename & ".xls")

               '\\\\\\\\\MyBase.BookPrintOut()
       End Loop2

MyBase.BookClose() 

End Loop1

 This code works fine, but instead of  saving it, I will just automatically print it.

Question is, If I use: MyBase.BookPrintOut(), it will just run on the first loop, and then a db error occurs.

What do you think is the proper format for printing in this case???

 Thanks in Advance!

Sheila


Rock on!!!
0
sheila_rt
3/27/2007 2:56:54 AM
asp.net.visual-basic.net 3721 articles. 0 followers. Follow

1 Replies
602 Views

Similar Articles

[PageSpeed] 30

Got it.

I found out that instead of "MyBase.BookPrintOut()", I should use "MyBase.SheetPrintOut("Name of the WorkSheet")".

 


Rock on!!!
0
sheila_rt
3/27/2007 7:46:33 AM
Reply:

Similar Artilces:

Sending SMS using vb.net or C#.net using vb.net or c#.net
Hi  My requirement is I hav one csv file with these fields id,mobilenum,messgae,status.intiallu staus is 0. once i read the all fileds and take that mobile number.using tat mobile number  i need to send sms .after sending sms i shuld change status as 1 How to send sms thru coding (please dont provide any links.if it is provide also please give working links becox i checked codeproject .i didnt get any nice link. and also provide the how to update the status field im csv file   Thank ssandhya   To send SMS, you need some third party SMS providers. if you consul...

Visual Studio .Net? Visual Basic .Net?
Okay, I admit it -- I know nothing about .Net. I'm a Visual Basic and ASP developer. DotNetNuke is my first tentative step into the whole ".Net Thing", and I'm looking for some advice... What do I really need to be able to make some modifications, or new modules for DotNetNuke? Do I need the full, THOUSAND DOLLAR Visual Studio .Net 2003 package, or can I get away with the HUNDRED DOLLAR Visual Basic .Net Standard package?Chameleon Systems, Inc. You can use webmatrix, available here for free. One of the drawbacks of webmatrix however is that it does not support code-be...

Visual Basic.NET or Visual Studio.NET?
OK, this has probably been asked before... I'm a student looking to cut my costs, and I can do this by just purchasing Visual Basic.NET as opposed to the fully-fledged Visual Studio.NET application. Of course, I'll only be able to program in VB, but that's fine with me. I wanted to know if all of the ASP.NET specific options are available, such as using a WYSIWYG editor? I'd also like to know if VB.NET has IntelliSense, or that's a specific option only available to Visual Studio.NET users. Thanks in advance. I'd have to believe that VB.Net has intellisense. What is the price d...

What are the diff. visual basic 6 and vb.net ? How to convert the VB6 project to vb.net proj ?
What are the diff. visual basic 6 and vb.net ? How to convert the VB6 project to vb.net proj ? with code and interface too. There are entire forums dedicated to the differences between the two, and to convert your projects you should try the upgrade wizard in Visual Studio....

Visual Basic.NET or Visual Studio.NET? #2
I am currently using the Web Matrix to develop ASP.NET applications, but I am keep to upgrade to VS.NET. However, I can't justify spending $1,000 at the moment. I then found the MUCH cheaper "Visual Basic .NET 2003 Standard Edition" which is only $100. I have very little C# knowledge, and use Basic almost all the time. Would this be a good tool to use for web development? Does it support all the code behind stuff that VS users love so much? Thanks!! I use "VB.NET Standard Edition" and I'm happy with it. It has exactly the same features as Visual Studio.NET. Th...

Visual Studio.Net and VB.Net
Can we install VS.Net and VB.Net on the same machine and work side by. Is there any thing I need to worry about? I use VS.Net enterprise for my office work and I am planning to buy VB.Net standard for my personal use. Before I goahead and buy, I wanted to make sure that it works. Thanks for your help. Anil...

converting to vb.net from c#.net authorize.net
authorize.net offered me some sample code when I signed up with them the only problem is the sample code is in c#.net but my page that they type all of their credit card into is vb.net <code><%@ Import Namespace="System.Net" %> <%@ Import Namespace="System.IO" %> <script language="C#" runat="server"> void Page_Load(Object Src, EventArgs E) { myPage.Text = readHtmlPage("https://certification.authorize.net/gateway/transact.dll"); } private String readHtmlPage(string url) { ...

converting vb.net 2003 files to vb.net 2005
Hi, i am beginner..i watch videos about vb.net..they made on vs.net 2003 when i wrote these codes in 2005 ,it gives errors..is there any program which convert the code automatically?   thanks,Thanks,Speranza What videos are you talking about?  There are lots of great, up-to-date ASP.NET Videos on this site for free.Darrell Norton, MVPDarrell Norton's BlogPlease mark this post as answered if it helped you! i am talking about learnvisualstudio.net videos..Thanks,Speranza Speranza:they made on vs.net 2003 when i wrote these codes in 2005 ,it gives errors..is there a...

Visual Basic .NET 2003 vs Visual Studio .NET 2003
Hi, If im going to be coding my ASP.NET in just VB.NET then would I be able to go for the cheaper option of buying Visual Basic .NET 2003 ?? - Carl S Yes.Starting with ASP.NET 2.0? Look at:Programming Microsoft Web Forms My Blog Are there any limitations if I was doing my ASP.NET with VB.NET in Visual Basic .NET 2003 than if I was using the full Visual Studio .NET 2003 ?? Or are the only advantages of Visual Studio .NET 2003 in that it supports more programming languages ?? - Carl S You should check the MS Web site, but I believe that, given an edition (Standard, Professional...

Net:Net:Net::LDAP::FAQ
------_=_NextPart_001_01C6429F.D89AA417 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello, Net::LDAP Net::LDAPS Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, ....) password? I don't like to write the secret password to the perl file. Best regards Barbara Wilbert ------_=_NextPart_001_01C6429F.D89AA417-- Wilbert Barbara (CI/OSI) * wrote: > Hello, > > Net::LDAP > Net::LDAPS > > Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, > ......

vb.net vs c#.net vs j#.net
just out of curiousity which looks, acts most like java? i'm still learning trying to used to vb.net but it seems that it was easier to do some stuff with java. C# is Java++ in my opinion. If you have done C or Jave you will prefer C#.Mike Schellenberger - MCAD If you are looking for language similar to java go for J#. However most code samples you find on the net will be in VB.NET and C#....

ADO.NET Programming in Visual Basic .NET
Has anyone read "ADO.NET Programming in Visual Basic .NET, Second Edition" by Steve Holzner (Author), Bob Howell (Author)? I am trying to working on a project and there are a few things that I need to tie up quickly in my web forms. Is this book a good one? karls------------------------------------'Old and wrinkled is not what I expected to become when I grew up!'...

use VB.NET and C#.NET code in the same C#.NET project
All-- Here is a sample that is "off the beaten path", (at least for me). Is it possible, in an ASP.NET application, using the code-behind page building technique, to have both pages written in VB.NET and pages written C#.NET?At http://www.WebLogicArts.com/DemoList.aspx there is a sample that shows that, (contrary to popular belief), it IS possible to mix ASP.NET pages built with C#.NET with ASP.NET pages built with VB.NET in the same VS.NET 2003 project. Note that this is just a "fun" sample to see if it can be done and I do not recommend this practice as a "standard" way of develo...

Visual Studio.NET VB.NET Edition for DNN?
I have been plugging along using the Handcoded method for Module Development up to this point and although I have been successful I'd like to possibly make the jump up to Visual Studio. I was looking at Microsot's Website and there is a VB.Net only version that lists for only $109 vs. the $1000+ for the full fleged Professional Edition. Is it possible to adequately develop for the DNN platform using this trimmed down (VB.NET only) version of Visual Studio 2003? The VB.NET 2003 package is more than adequate for DDN moodules or full-blown ASP.NET applications. Highly recommended... mi...

Web resources about - How to Print Excel File In VB.Net??? - asp.net.visual-basic.net

Welcome - Net Objectives Net Objectives - Scrum Agile Training & Agile Development - TDD, Agile Scrum ...
Deliver value to your customers faster. NetObjectives.com is the industry leader in agile scrum training, scrum methodology, lean agile training, ...

經濟通 ET Net- 港股財經基金投資- 免費即時股票報價 HK Free Real Time Stock Quote
Copyright 2012 ET Net Limited. http://www.etnet.com.hk ET Net Limited, HKEx Information Services Limited, its Holding Companies and/or any Subsidiaries ...

Net income - Wikipedia, the free encyclopedia
Net income can be distributed among holders of common stock as a dividend or held by the firm as an addition to retained earnings . As profit ...

Contract Analyst Programmer (Reporting/.Net) 151223/AP/266
Defining Technology for Australia's IT Leaders.

Video Net Tastemade Raises $40 Million From Goldman Sachs, Others
... has raised isn't as interesting as who's giving the company that money. Take Tastemade for example. The three-year-old digital video network ...

How to find which versions of the .NET Framework are installed on a PC
Check the system requirements for a Windows application and you’ll often find it needs some minimum version of Microsoft’s .NET Framework. .NET ...

Mikhail Prokhorov invested another $400 million in the Brooklyn Nets - Business Insider Deutschland
The Russian oligarch previously owned 80% of the Nets and Barclays Center, and now owns 100% of both after buying out Bruce Ratner's shares. ...

Modified Net Metering To Take Place In Mississippi
Mississippi will become the 46th state to implement net metering for owners generating renewable electricity with solar panels or wind. However, ...

Kickstarter, Tumblr, Etsy, Others Ask Lawmakers To Not Use Budget To Ruin Net Neutrality
While the telecom industry is fighting the bad fight against net neutrality through the legal system — the way such matters are supposed to be ...

Cable Net Z Living Inks Development Deal With 3 Ball Entertainment
Health entertainment network Z Living has closed a development deal with 3 Ball Entertainment ( Bar Rescue, Extreme Weight Loss ), the first ...

Resources last updated: 12/24/2015 4:06:57 AM