Exforsys

Online Training

Problem in visual basic......????

This is a discussion on Problem in visual basic......???? within the Visual Basic Tutorials forums, part of the Articles and Tutorials category; I want to print the numbers 1 to 99. i have written the following code: private sub cmdCommand1_click() dim i ...


Go Back   Exforsys > Articles and Tutorials > Visual Basic Tutorials

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 10-01-2007, 09:37 AM
Junior Member
 
Join Date: Apr 2007
Posts: 2
anmol004@gmail. is on a distinguished road
Problem in visual basic......????

I want to print the numbers 1 to 99.
i have written the following code:

private sub cmdCommand1_click()
dim i as integer
for i = 1 to 99
print i
next i
end sub

What's wrong with this coding? The output of above is all the numbers from 1 to 16?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 10-03-2007, 04:02 PM
Junior Member
 
Join Date: Aug 2007
Location: Indian living in UAE
Posts: 4
ganeshmoorthy is on a distinguished road
Send a message via MSN to ganeshmoorthy Send a message via Yahoo to ganeshmoorthy
where do you want to print, on the form or to the printer. If on the form, this code is correct and working fine. If you want to print on the printer then the code should be
Dim i As Integer
For i = 1 To 99
Printer.Print i
next i
Printer.EndDoc
try this and revert me if this is want you wanted
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 10-08-2007, 09:20 AM
Junior Member
 
Join Date: May 2007
Posts: 1
velskvm is on a distinguished road
Thumbs up use scrollbar to see the remaining numbers

use scrollbar to see the remaining numbers
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 04-29-2008, 05:10 PM
Junior Member
 
Join Date: Apr 2008
Location: pune
Posts: 4
sourabhroy2586 is on a distinguished road
Quote:
Originally Posted by anmol004@gmail. View Post
I want to print the numbers 1 to 99.
i have written the following code:

private sub cmdCommand1_click()
dim i as integer
for i = 1 to 99
print i
next i
end sub

What's wrong with this coding? The output of above is all the numbers from 1 to 16?
its working fine buddy
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads

Thread Thread Starter Forum Replies Last Post
Visual Basic : Make the Transition from Traditional Visual Basic Error Handling to the Object-Oriented Model in .NET techguru Visual Basic Tutorials 0 08-29-2005 07:27 AM
Visual Basic : Taking the Visual out of Visual Basic techguru Visual Basic Tutorials 0 08-29-2005 03:27 AM
Visual Basic : Security Concerns for Visual Basic .NET and Visual C# .NET Programmers techguru Visual Basic Tutorials 0 08-29-2005 01:27 AM
Visual Basic : Discover a Series of Fortunate Event Handlers in Visual Basic techguru Visual Basic Tutorials 0 08-28-2005 05:26 PM
Visual Basic : A Primer on Creating Type-Safe References to Methods in Visual Basic .NET techguru Visual Basic Tutorials 0 08-27-2005 11:26 PM


All times are GMT -4. The time now is 03:19 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0
Copyright 2004 - 2007 Exforsys Inc. All rights reserved.