473,412 Members | 2,994 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,412 software developers and data experts.

Runtime error 91

143 100+
Hello everyone..
I m working on VB6 and SQLServer 2000.... i m getting an error in this line..


Private Sub txtAdjAmt_KeyPress(KeyAscii As Integer)
Dim vI As Integer
vI = LVPO.SelectedItem.Index
If KeyAscii = 13 Then
LVPO.ListItems(vI).SubItems(4) = txtAdjAmt.Text
txtAdjAmt.Visible = False
End If

Dim vI1 As Integer
vI1 = LvBill.SelectedItem.Index
If KeyAscii = 13 Then
LvBill.ListItems(vI1).SubItems(4) = txtAdjAmt.Text
txtAdjAmt.Visible = False
End If
End Sub


is anyone there to help me out to remove the error... there is a textbox when i press any key it give an error as " object variable or with block variable not set"
plz help me.
thank u in advance
Nov 26 '08 #1
6 1217
QVeen72
1,445 Expert 1GB
Hi,

May be, No Item is selected in the list view "LvBill"

Regards
Veena
Nov 26 '08 #2
squrel
143 100+
Hi

the selection is done bt still i m getting the same error.
can u help me out
thank u
Nov 26 '08 #3
QVeen72
1,445 Expert 1GB
Hi,

How are you populating "lvBill"....?
Nov 26 '08 #4
squrel
143 100+
Private Sub LvBill_KeyPress(KeyAscii As Integer)
Dim vI1 As Integer
'If cmbpayType.Text = "B" Then
If LvBill.CheckBoxes = True Then
vI1 = LvBill.SelectedItem.Index
txtadjamt1.Left = LvBill.ColumnHeaders(5).Left + 280

txtadjamt1.Top = LvBill.ListItems(vI1).Top + 3600
txtadjamt1.Height = LvBill.ListItems(vI1).Height
txtadjamt1.Width = LvBill.ColumnHeaders(5).Width
txtadjamt1.Visible = True
txtadjamt1.Text = ""
txtadjamt1.SetFocus
End If
'End If
End Sub


this is my lvbill... i have one more lvbillpo which by filling up the lvbill and saving the listview wil show.. i have to set the adjamt and tdsamt in the lvbill to get tht..
Nov 26 '08 #5
QVeen72
1,445 Expert 1GB
Hi,

Change you Code like this and Check :

Expand|Select|Wrap|Line Numbers
  1. Private Sub txtAdjAmt_KeyPress(KeyAscii As Integer)
  2. Dim vI As Integer
  3. If KeyAscii = 13 Then
  4.     vI = LVPO.SelectedItem.Index
  5.     LVPO.ListItems(vI).SubItems(4) = txtAdjAmt.Text
  6.     txtAdjAmt.Visible = False
  7. End If
  8.  
  9. Dim vI1 As Integer
  10. If KeyAscii = 13 Then
  11.     vI1 = LvBill.SelectedItem.Index
  12.     LvBill.ListItems(vI1).SubItems(4) = txtAdjAmt.Text
  13.     txtAdjAmt.Visible = False
  14. End If
  15. End Sub
  16.  
Regards
Veena
Nov 26 '08 #6
squrel
143 100+
ok.. thank u very much
Nov 28 '08 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Bob Bamberg | last post by:
Hello All, I have been trying without luck to get some information on debugging the Runtime Error R6025 - Pure Virtual Function Call. I am working in C++ and have only one class that is derived...
5
by: Nathan Bloom | last post by:
Hi, I have a secured database that runs fine on the computer the database is installed on. I have several workstations with access runtime installed that also need access to the database. ...
2
by: Paul | last post by:
I'm hoping someone can help me with the problem. I have a database where the default value for a date field in a table is =date() This works perfectly in my table and on my form. But when I...
12
by: Markus Ewald | last post by:
I'm just experimenting around with the VisualC++ 2005 Express Edition Beta and found some strange behavior for which I can't seem to find a workaround. What I've done is set up two static library...
0
by: Kirk | last post by:
I'm trying to use a Web Service to be a Remoting client of an existing ..NET 2.0 server. But I get the following error when I try to use System.Runtime.Remoting.Channels.Http in my WebService. ...
0
by: zfraile | last post by:
I'm getting this error from the JIT compiler at runtime, but only on my boss' machine, not my development machine. I believe the error is generated from a call to an Excel object, but I can't tell...
0
by: Yelena Varshal via AccessMonster.com | last post by:
Hello We have a shortcut for our MS ACCESS application that uses a /Runtime switch because we may have some users that use Runtime. The application worked fine in Access 2000 and was tested with...
7
by: Norman Diamond | last post by:
A project depends on VC runtime from Visual Studio 2005 SP1, and DotNet Framework 2. Options are set in the setup project properties, so if these two dependencies are not already installed then...
3
by: Jim Armstrong | last post by:
Hello all - This is driving me crazy. I have a table called tblClients - very simple, has the following fields: taxID (PK) ClientName SalesName The main form of my application allows a...
1
by: BL3WC | last post by:
Hi, I'd created a MDE under Access 2003. It is now under testing stage. Some of the users will use Access 2003 runtime and some will use Access 2007 runtime to run this MDE. I installed the...
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:
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

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.