Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

populating textfield using combobox access 2007, sql 2008

Posted on 2011-09-17
8
Medium Priority
?
238 Views
Last Modified: 2012-05-12
Hi,

Have a subform in my form:

There is a combo box which displays taskID and TaskDescription and bound TaskID to the combobox. and should display taskdescription in the textfield beside it and then automatically display the next row of combobox and textfield for the second entry.

The problem I have, I can not populated the textfield after making a selection. I keep getting #Name? in this text field.

Here are how combobox and textfield set up:

TaskID  TaskDescription

TaskID
All: cmb_task
control source: TaskID
AfterUpdate:Event Procedure : Me!Task = cmb_task.Column(1)

Data:
control source: taskID
row source: select taskID, task from task  bound column: 1,

TaskDescription:
Name: Task
controlsource: Task

Date: control source: TASK

how can I get this fixed. (when I make the task textfield unbound, then it does not add the second row...)

thanks in advance




0
Comment
Question by:shmz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 12

Expert Comment

by:pdebaets
ID: 36555142
Is TaskDescription in your combo box rowsource?
0
 

Author Comment

by:shmz
ID: 36555196
The row source for combobox is the select statement: select taskID, taskdescrription from task.
Bound column is 1.
0
 
LVL 12

Expert Comment

by:pdebaets
ID: 36555202
If your combo box is named MyComboBox, then try setting your task description textbox control source to

=MyComboBox.Column(1)
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 

Author Comment

by:shmz
ID: 36555228
That is exactly what is done but it is not working:

TaskID
All: cmb_task
control source: TaskID
AfterUpdate:Event Procedure : Me!Task = cmb_task.Column(1)
0
 
LVL 12

Accepted Solution

by:
pdebaets earned 2000 total points
ID: 36555251
I'm not sure if we're talking about the same thing here.

It sounds like you have a text box that you want to have display the task description. If so, set the text box control source to "=cmb_task.Column(1)"

If i'm misunderstanding, please set me straight.
0
 

Author Comment

by:shmz
ID: 36555279
It was initially set in the after update event of TaskID combobox.
If I understood you correctly, I removed initial code and I added "=cmb_task.Column(1)"
to the control source of textfield in the property sheet.

unfortunately it is still displaying the #Name?
0
 
LVL 12

Expert Comment

by:pdebaets
ID: 36555469
Let's verify the name of your combo box control. Is it "cmb_task", or is it named something else?
0
 

Author Closing Comment

by:shmz
ID: 36595389
thanks
0

Featured Post

Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question