Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > VB.NET
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
VB.NET General VB.NET discussions for issues that don't fall into other VB.NET forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 23rd, 2005, 11:02 AM
Authorized User
 
Join Date: Nov 2005
Location: , , United Kingdom.
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default Datagrid scroll count (Lines) VB.NET 2003

Hi,

Is it possible to get the scroll value from a datagrid vertical scroll bar. If I scroll the side bar down by 3 lines I want to beable to retrieve the value 3 from the datagrid vertical scroll bar. I'm writing a program what utilises the datagrid but when it scrolls down it throws out the calculations. Is there a way to get the scroll value?

I have tried adding a handler but that only tells me that the scroll bar has been moved, not if it has been moved up or down

Thanks

Pete*
__________________
Simplicity is the key
Reply With Quote
  #2 (permalink)  
Old November 23rd, 2005, 07:53 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: , , .
Posts: 540
Thanks: 0
Thanked 4 Times in 4 Posts
Default

I don't think it exposes this property. You may have to attach a <s>horizontal</s> vertical scrollbar to your form and calculate it this way.

J
Reply With Quote
  #3 (permalink)  
Old November 24th, 2005, 04:49 AM
Authorized User
 
Join Date: Nov 2005
Location: , , United Kingdom.
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default

OK, I tried do do that but I just could notn think of a way to do it. Anyway It just so happens that I downloaded a copy of Visual Basic 2005 express Edition. The fully working frebie directly from microsoft earlier this month. I decided to install it on my lappers and convert my projust into it to see if that would help. It did. The new datagrid has tons of options that is not in my Visual Basic 2003, part of my Visual Studio 2003 enterprise. This includes an easy way to count rows and columns without using the dataset or datatable and datagrid.VerticalScrollingOffset which I used lastnight to calulate how far the vertical scroll has moved. You should try it out. it's fully working and free to use until Nov 6th 2006. After that it shoulf cost around $49

Thanks

Pete*
Reply With Quote
  #4 (permalink)  
Old November 24th, 2005, 04:26 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: , , .
Posts: 540
Thanks: 0
Thanked 4 Times in 4 Posts
Default

Nice info. I have Visual Studio 2005 but have not had a chance to try it out. I am really looking forward to the new features.

From what I have seen this should be possible using a vertical scrollbar, but if it is done for you in 2005 why put in the time.

J
Reply With Quote
  #5 (permalink)  
Old November 24th, 2005, 05:34 PM
Authorized User
 
Join Date: Nov 2005
Location: , , United Kingdom.
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I'm wondering what ur idea was for using the vertical scrollbar with a datagrid. As I said b4 I did think of it but could not think of a way to utilise it. VB.NET 2005 is really good. The only thing I don't like is that the datagridview is slow at populating. it takes about 8 seconds. A datagrid in vb.net 2003 takes about 5 seconds and a datagris in VB6 takes about 3 seconds. These figures relate to populating 36521 lines of data from a MS access DB with 7 columns. I manually program in the populate routine using a dataset not dragging & dropping in VB/ASP.

Thanks Pete*

P.S. I have just tried the free version of ASP.NET 2005, Wow it's good. I'm just about to try and convert one of my asp site. That should be funny.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
help, converting vb.net few lines to C# nesrine C# 3 March 6th, 2007 10:43 AM
Print Datagrid in vb.net 2003 rngrmn VB.NET 2002/2003 Basics 0 April 6th, 2006 04:23 PM
Datagrid scroll count (Lines) VB.NET 2003 peterasimpson VB How-To 1 November 24th, 2005 12:33 AM
DataGrid in VB.Net 2003 madhanagopal Pro VB.NET 2002/2003 0 August 3rd, 2004 05:33 AM



All times are GMT -4. The time now is 05:32 PM.


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