473,770 Members | 1,862 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Access Automating

Hello all, I have been searching the net endlessly and found this ng, so I
thought I would give a try. Anyways, I have a few problems I am trying to
implement a combo box which presently contains the following: Description,
Price, and Treatment code. I wish to do the following: when the description
field(combo box) is clicked I want the price, treatment code, insured field
to become automated(updat e the corresponding data automatically). At the
present time 3 out the for 4 fields are updating fine. Basically the
description field contains the products and services offered. I used a check
box(boolean value) to be able to tell the difference as to what insurance %
should be applied,however , it is not working. Furthermore, the field used
for the insured % is used further for more calculations. Is there not a way
I can just set the field to read to the correct value in visual basic. I get
the following error at the present time.

Run-time error ' 2147352567(8002 0009)'
You can't assign a value to this object.

Private Sub ProductID_After Update()
Me![UnitPrice] = Me![ProductID].Column(2)
Me![ProductCode] = Me![ProductID].Column(3)
Me.Foot = Me![ProductID].Column(4)
Me.Pod = Me![ProductID].Column(5)


End Sub

any feed back greatly appreciated.
Thanks in advance
Jun 26 '06 #1
2 3227
Which field isn't updating, and what kind of control is it? I don't
understand why you're trying to duplicate the information on the form,
because you're pulling the values from your dropdown.

I notice you're also using dots and bangs interchangeably . You may
want to browse through this as it may also be part of your problem:

Addressing Objects and Collections
Access provides a method that lets you address anything within your
database. Since objects and collections form a hierarchical system, it
may be helpful to compare the Access address system to a similar system
you should already be familiar with--the directory structure on your
disk drive.

As you move through different levels in a directory structure, you
indicate a change in level using a backslash. For example, consider the
following pathname:

C:\WINDOWS\SYST EM\SYSEDIT.EXE

As you read the pathname from right to left, you learn that the
SYSEDIT.EXE file is in the SYSTEM directory, which is within the
WINDOWS directory, which is on the C: drive. Each backslash indicates
you are moving down a level in the directory structure, when reading
from left to right. In Access, you use exclamation points (!) and
periods (.) to denote changes in the level. The exclamation points are
called bangs, and the periods are called dots. The general rules which
govern the use of bangs and dots are as follows:

You use a bang before objects you have named.
If a name contains spaces, you surround it with brackets, as in [Zip
Code].
You use a dot before objects, properties, or methods named by Access.

How do you apply these rules? Simple. Suppose you want to refer to the
Business Customers table you created earlier in this book. This table
is part of the Customer database, so you can address it as follows:

Customer![Business Customers]

Notice the brackets around the table name and the bang between levels
of the hierarchy. If you want to refer to a property within the table,
you can use a dot and the property name, as in the following:

Customer![Business Customers].RecordCount

Michael Bialowas wrote:
Hello all, I have been searching the net endlessly and found this ng, so I
thought I would give a try. Anyways, I have a few problems I am trying to
implement a combo box which presently contains the following: Description,
Price, and Treatment code. I wish to do the following: when the description
field(combo box) is clicked I want the price, treatment code, insured field
to become automated(updat e the corresponding data automatically). At the
present time 3 out the for 4 fields are updating fine. Basically the
description field contains the products and services offered. I used a check
box(boolean value) to be able to tell the difference as to what insurance %
should be applied,however , it is not working. Furthermore, the field used
for the insured % is used further for more calculations. Is there not a way
I can just set the field to read to the correct value in visual basic. I get
the following error at the present time.

Run-time error ' 2147352567(8002 0009)'
You can't assign a value to this object.

Private Sub ProductID_After Update()
Me![UnitPrice] = Me![ProductID].Column(2)
Me![ProductCode] = Me![ProductID].Column(3)
Me.Foot = Me![ProductID].Column(4)
Me.Pod = Me![ProductID].Column(5)


End Sub

any feed back greatly appreciated.
Thanks in advance


Jun 27 '06 #2
Hello, thank you for you immediate response. I was able to correct that
problem of spliting the insurance field into two separate fields. However,
at the present time I still have a problem. The problem is giving me an
error which is run-time error '13' type mismatch. The odd thing is that all
3 fields have the same data type and format. I am using a drop down combo
box for the productName and depending on which product is selected the
proper insurance field should become automated; which it does. However, I am
using another field that is to be used while doing some calculations on that
data. So, I wish to store the proper insurance into the corresponding
insurance field then assign that value to another field so that the
calculations can be made on that value. Right now I am able to select one
type of product which works perfectly, however, when I select the other type
of product which has a different insurance plan I get the run time error.
Here is a snippet of what I have right now that is causing the problem.

Private Sub Combo106_AfterU pdate()
Me![UnitPrice] = Me![Combo106].Column(1)
Me![ProductCode] = Me![Combo106].Column(2)
Me![Pod] = Me![Combo106].Column(3)
Me![Foot] = Me![Combo106].Column(4)

If Me![Combo106].Column(3) Then
Me![Discount].Value = Me![Combo106].Column(3)
Else
Me![Discount].Value = Me![Combo106].Column(4)
End If

Any feedback is greatly appreciated.
Thanks in advance...
"ManningFan " <ma********@gma il.com> wrote in message
news:11******** *************@p 79g2000cwp.goog legroups.com...
Which field isn't updating, and what kind of control is it? I don't
understand why you're trying to duplicate the information on the form,
because you're pulling the values from your dropdown.

I notice you're also using dots and bangs interchangeably . You may
want to browse through this as it may also be part of your problem:

Addressing Objects and Collections
Access provides a method that lets you address anything within your
database. Since objects and collections form a hierarchical system, it
may be helpful to compare the Access address system to a similar system
you should already be familiar with--the directory structure on your
disk drive.

As you move through different levels in a directory structure, you
indicate a change in level using a backslash. For example, consider the
following pathname:

C:\WINDOWS\SYST EM\SYSEDIT.EXE

As you read the pathname from right to left, you learn that the
SYSEDIT.EXE file is in the SYSTEM directory, which is within the
WINDOWS directory, which is on the C: drive. Each backslash indicates
you are moving down a level in the directory structure, when reading
from left to right. In Access, you use exclamation points (!) and
periods (.) to denote changes in the level. The exclamation points are
called bangs, and the periods are called dots. The general rules which
govern the use of bangs and dots are as follows:

You use a bang before objects you have named.
If a name contains spaces, you surround it with brackets, as in [Zip
Code].
You use a dot before objects, properties, or methods named by Access.

How do you apply these rules? Simple. Suppose you want to refer to the
Business Customers table you created earlier in this book. This table
is part of the Customer database, so you can address it as follows:

Customer![Business Customers]

Notice the brackets around the table name and the bang between levels
of the hierarchy. If you want to refer to a property within the table,
you can use a dot and the property name, as in the following:

Customer![Business Customers].RecordCount

Michael Bialowas wrote:
Hello all, I have been searching the net endlessly and found this ng, so I thought I would give a try. Anyways, I have a few problems I am trying to implement a combo box which presently contains the following: Description, Price, and Treatment code. I wish to do the following: when the description field(combo box) is clicked I want the price, treatment code, insured field to become automated(updat e the corresponding data automatically). At the
present time 3 out the for 4 fields are updating fine. Basically the
description field contains the products and services offered. I used a check box(boolean value) to be able to tell the difference as to what insurance % should be applied,however , it is not working. Furthermore, the field used for the insured % is used further for more calculations. Is there not a way I can just set the field to read to the correct value in visual basic. I get the following error at the present time.

Run-time error ' 2147352567(8002 0009)'
You can't assign a value to this object.

Private Sub ProductID_After Update()
Me![UnitPrice] = Me![ProductID].Column(2)
Me![ProductCode] = Me![ProductID].Column(3)
Me.Foot = Me![ProductID].Column(4)
Me.Pod = Me![ProductID].Column(5)


End Sub

any feed back greatly appreciated.
Thanks in advance

Jun 27 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
2052
by: Mark Lees | last post by:
How does one increase their Access skills? I'm creating a basic DB for a non-profit organization. I would classify myself as an advanced beginner. I've got some help books but it seems they will only take me so far. Some of the threads I've read here are way over my head. How do I become better?
4
2635
by: Andrew Chanter | last post by:
I have a VB app that has a routine that runs macros in a (password protected) Access 97 db. (I have attached the code below.) Most of these macros end up opening a form in the Access db for the user to interract with.When the user finishes in the Access session they quit and are returned to the VB app. Problem is that in many cases, when the user quits the Access session, an Access 'shell' remains in the taskbar that cannot be removed...
8
3538
by: Mike MacSween | last post by:
tblCourses one to many to tblEvents. A course may have an intro workshop (a type of event), a mid course workshop, a final exam. Or any combination. Or something different in the future. At the moment the printed output is usually going to Word. It's turning into an unholy mess, because I'm having to prepare umpteen different Word templates, and the queries that drive them, depending on what events a course has.
12
34829
by: Bookreader | last post by:
I tried Googling this but I get a whole lot of replies about running the SQL statement in VB via ADO. All I want to do is run an existing ACCESS 2000 query from VB with no information returned to VB. I am presuming that I would use Automation somehow. Thanks in advance.
4
3232
by: Supa Hoopsa | last post by:
I am in the process of rewriting an MS Access application (access front end with SQL 2k database) in VB.NET and one of the things I would like to do is link in to the compiled Access ADE so that I can use the reports that have already been created. I have somewhere in the region of 200 reports already created in MS Access and I really don't want to have to create new ones. I have successfully linked to the Access ADP, but would really like to...
1
5740
by: garry.oxnard | last post by:
Can anyone help me to solve a problem which involves switching from Access to Excel (then back to Access) programatically please? I have an Excel template which, on open, also opens an Access database - containing a list of addresses. Sequence of events is = (1) Excel template opens in its default XXX.xls filename. (2) Code runs to save the spreadsheet as XXX.xls. (3) User clicks a button to open an Access database containing an
5
1867
by: Kip | last post by:
I have an office with approx 8 people. I have used Access with a Form on my personal PC for client records. I was wondering if I could put the Access table on a server and put shortcuts on each work station to allow users to view, update records? Thanks in advance
4
3203
by: attachmatey | last post by:
Greetings: I'm looking for some help in automating (what I thought would be) a simple procedure in Internet Explorer. I'm trying to put the following operation under a button click in an MS Access database form: 1. Navigate to URL and click button 2. Enter user name and password 3. Apply filters (enter criteria in text boxes) 4. Execute query (another button click) 5. Export results to network server 6. Data mining using Monarch...
4
1115
by: khan091 | last post by:
m automating ie ,want to access the lists in it ,can any one help me out ????
13
2543
by: evancater | last post by:
My client wants to make their Access 2007 database available to offices around the country with multi-user permissions set to control access to the tables and forms, etc. The easiest thing would be a client/server app, but they are concerned that accessing the backend on their VPN would be too slow. We've discussed the possibility of publishing the forms to the intranet with ASP, but I'm concerned that web development with Access is a...
0
9617
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9454
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10099
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9904
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7456
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6710
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5354
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4007
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.