473,721 Members | 2,133 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

MS Access: Binding a Textbox to a Pivot Table Cell

9 New Member
Hello,

I have an Access Data Access Page which has a pivot table. The data source of the pivot table is a SQL database table. The data in the pivot table itself is not a problem.

I have a text box below the pivot table. Let's say the pivot table has: First Name, Last Name, and Address. When I click on a record in the pivot table, I want the Address for that selected record to be displayed in the textbox below.

What I have currently done is create a textbox and in the ControlSource of the textbox I put the Address field name. However, the content of the textbox is not changing when I click on different records in the pivot table. It does change when I go to the next record from the Record Navigation.

So if someone could help me tie the textbox value to the cell in the pivot table record that has focus I would be very grateful!

Thank you,
Oct 12 '06 #1
5 4542
Mistoffeles
5 New Member
Your code needs to go on the table, and be based one the event triggered when focus is changed to a particular record, or a different record. Your code should send the address field data for the selected record to the text box.

I couldn't tell you how to do this in specific code, or I'd be able to solve my own problem posted here 8^D, but that should give you an idea what you need to do.
Oct 12 '06 #2
Pourya99
9 New Member
Your code needs to go on the table, and be based one the event triggered when focus is changed to a particular record, or a different record. Your code should send the address field data for the selected record to the text box.

I couldn't tell you how to do this in specific code, or I'd be able to solve my own problem posted here 8^D, but that should give you an idea what you need to do.
I haven't written any code to create the table. I just used the design view and dropped things in. I'm not sure where I would even put the code. I have been searching for the click event for the record, but I havent found anything regarding that. I think pivot tables work differently in data access pages than they do in forms. Thanks for your input.
Oct 12 '06 #3
Pourya99
9 New Member
bump. Somoene please help :)
Oct 13 '06 #4
Pourya99
9 New Member
someone? anyone?
Oct 16 '06 #5
MMcCarthy
14,534 Recognized Expert Moderator MVP
You need to put code in the Form_OnCurrent event to requery the textbox.

Expand|Select|Wrap|Line Numbers
  1.  
  2. Private Sub Form_OnCurrent()
  3.  
  4.   Me.textboxName.Requery
  5.  
  6. End Sub
  7.  
  8.  
Hello,

I have an Access Data Access Page which has a pivot table. The data source of the pivot table is a SQL database table. The data in the pivot table itself is not a problem.

I have a text box below the pivot table. Let's say the pivot table has: First Name, Last Name, and Address. When I click on a record in the pivot table, I want the Address for that selected record to be displayed in the textbox below.

What I have currently done is create a textbox and in the ControlSource of the textbox I put the Address field name. However, the content of the textbox is not changing when I click on different records in the pivot table. It does change when I go to the next record from the Record Navigation.

So if someone could help me tie the textbox value to the cell in the pivot table record that has focus I would be very grateful!

Thank you,
Oct 16 '06 #6

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

Similar topics

1
2923
by: Abareblue | last post by:
I have no clue on how to insert a record into access. here is the whole thing using System; using System.Drawing; using System.Collections; using System.ComponentModel;
1
3144
by: Grey | last post by:
I have created a asp.net form for user to input data. After input the data, user need to click a button to export the input data to excel for data analysis with excel pivot table function. is it possible to do that?? if so, any sample for me as i am a new in designing pivot table with asp.net million thanks
3
10264
by: Jerry K via DotNetMonster.com | last post by:
I'm creating a pivot table using vb.net and the data is from sqlserver (desktop). I have been successful at creating the pivot table, which includes a 'date' column field. I'd like to group the date column field by months and quarters, but can't come up with the correct code. Here is the code I've written to create the pivot table. Any help to code grouping the date column field would be appreciated. Thanks, Jerry
1
7349
by: kingster | last post by:
Hi, I have a regular dataset and all i want to do is make a pivot table display in a browser with the datasource of the pivot table to be this dataset and then the end-user will be able to do whatever they want ... i dont need to do any special formatting just a straigh ot pivot tables usign sql server, asp.net, vb.net, OWC 10
3
2993
by: nvx | last post by:
Hello everyone... Just for the record, I'm a newbie to this data binding thing... In my C# application I need to bind a cell of an Access database table to a multiline TextBox. How should I do it? I've tried to bind the TextBox using the VS IDE (which ended up in binding to a table column). This was perfect until I used the Update command. Then an exception was thrown, telling me, that to update a database it needs to have a DataRow...
0
1803
by: comp974 | last post by:
ok, here is the situation, I am trying to construct a table with several ASP.net 2.0 controls in it during execution time in an VB.net enviroment. For starters, I have a textbox and a linkbutton per row of the table. I have easily constructed the table, but on the postback, I am unable to access the controls... Here is an example of the code: ''' <summary>Page Load</summary> ''' <remarks> ''' <para>Ensure that the querystring has a...
0
1336
by: Pourya99 | last post by:
Hello, How do a extract the value of one field from the currently selected record in a pivot table? I am currently using the following event: <SCRIPT language=vbscript event=SelectionChange for=PivotTable0> Text0.value = MSODSC.Datapages(0).Recordset.....
1
4748
by: Paul H | last post by:
I have a very simple database containing one table called "tblProducts". The fields are: ProductID, Description, Price. I have a folder on my PC that contains image files. The image file names are based on the associated ProductID, i.e. 2001.jpg is a picture of ProductID 2001. I know how automate Word mailmerge using VBA in access, but I want to include the related pictures in the merged document. So the word doc will have a table in...
2
1392
by: =?Utf-8?B?cm9kY2hhcg==?= | last post by:
hey all, i have an incoming datatable in my web page and i'd like to bind one of the fields to a textbox. can someone please show me how to do this? thanks, rodchar
0
8730
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
9367
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9215
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...
1
9131
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9064
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...
0
4484
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
4753
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3189
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
3
2130
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.