Senin, 11 Desember 2017

Re: [MS_AccessPros] Populate Textbox On Another Form From Listbox,

 

Art, 

You said you tried "Refesh". What did you refresh? Did you try Requery the list box? This will only make a difference after the record in the table has been saved. 


I have also used:

[Forms]![frmCabinetDetailsNew]![lsteIndexFields].RowSource = [Forms]![frmCabinetDetailsNew]![lsteIndexFields].RowSource


You could also open the second form in acDialog mode and add a line to requery the list box after the line to open the form.


Regards,

Duane Hookom




From: MS_Access_Professionals@yahoogroups.com <MS_Access_Professionals@yahoogroups.com> on behalf of Art Lorenzini dbalorenzini@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com>
Sent: Monday, December 11, 2017 2:02 PM
To: Duane Hookom duanehookom@hotmail.com [MS_Access_Professionals]
Subject: Re: [MS_AccessPros] Populate Textbox On Another Form From Listbox,
 


The user can may need to modify the an item in the list box. So let's say the Item they choose is Company and they want to change it to Company Name. The specification states I need to open a form and populate with the selected item from the list box and then save the changes back to the list box. I tried the Refresh and it did not work.


With Warm Regards,
 
Arthur D. Lorenzini
IT System Manager
Cheyenne River Housing Authority
Wk.(605)964-4265  Ext. 130
Fax (605)964-1070

"Valar Dohaeris"






On ‎Monday‎, ‎December‎ ‎11‎, ‎2017‎ ‎12‎:‎56‎:‎24‎ ‎PM, Duane Hookom duanehookom@hotmail.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:


 

Hi Art,


You might want to try:

[Forms]![frmCabinetDetailsNew]![lsteIndexFields].Requery


I'm not sure why you are updating the list box but as long as you understand it's good with me.


Regards,

Duane



From: MS_Access_Professionals@yahoogroups.com <MS_Access_Professionals@yahoogroups.com> on behalf of Art Lorenzini dbalorenzini@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com>
Sent: Monday, December 11, 2017 12:42 PM
To: Duane Hookom duanehookom@hotmail.com [MS_Access_Professionals]
Subject: Re: [MS_AccessPros] Populate Textbox On Another Form From Listbox,
 


I got it to work when I am opening up the second for to edit the indexfield but after the edit when I want to update the listbox I tried this:

 

Private Sub cmdSave_Click()

    If Not SaveIt() Then Exit Sub ' this is a save function

    [Forms]![frmCabinetDetailsNew]![lsteIndexFields].Form.Requery

    ' Close me

    DoCmd.Close acForm, Me.Name

End Sub

 

But it error's out with Object doesn't support this property or method




With Warm Regards,
 
Arthur D. Lorenzini
IT System Manager
Cheyenne River Housing Authority
Wk.(605)964-4265  Ext. 130
Fax (605)964-1070

"Valar Dohaeris"






On ‎Sunday‎, ‎December‎ ‎10‎, ‎2017‎ ‎08‎:‎40‎:‎27‎ ‎PM, Duane Hookom duanehookom@hotmail.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:


 

NArt,
Have you gotten anywhere with this? There is a double click event of the listbox to write your Code. You need to include OpenArgs to send a value to the form you are opening. When the new form is opened use Code to check the OpenArgs and set the control value.

Try it and let us know how far you get. If you have questions please come back with your Code.

Regards,
Duane


From: MS_Access_Professionals@yahoogroups.com <MS_Access_Professionals@yahoogroups.com> on behalf of dbalorenzini@yahoo..com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com>
Sent: Sunday, December 10, 2017 6:59:20 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: [MS_AccessPros] Populate Textbox On Another Form From Listbox,
 


I have a form called frmeCabinetDetailsNew and on it I have a listbox called lsteIndexField. If the user double clicks on a item in the list box I need to open up a from called frmeindexField which has a textbox called txtIndexField and populate it with the selected item from the listbox on the other form for editing. Once its edited I need to save the changes back to frmeCabinetDetailsnew.lsteIndexField. Any ideas?


Thank you,


Art Lorenzini

SD







__._,_.___

Posted by: Duane Hookom <duanehookom@hotmail.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (7)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

Tidak ada komentar:

Posting Komentar