Combo and text box dependency

On my form I have a combo box (cboRepairType) which retrieves its list from 
field(1) of tblGrips. Once the selection has been made (AfterUpdate I 
presume) I would like the corresponding value from field(3) of tblGrips to 
display in a text box (txtSellPrice), (or would another type of display be 
more appropriate?)
Can this be done?

Please be gentle I am a novice at this :-)
Sandy 


0
Sandy
11/20/2007 8:18:36 PM
access 16762 articles. 3 followers. Follow

9 Replies
726 Views

Similar Articles

[PageSpeed] 23

Hi Sandy,

Yes, it can be done. Use the Afterupdate event procedure, as you have 
indicated. In VBA code, the columns are "zero-based", so the first column of 
the rowsource would be column(0), the second column would be column(1), etc. 
You must include the the corresponding value from field(3) in the rowsource 
for your combo box. So, for example, if field(3) from the table was the 
second field in the rowsource, ie.

SELECT Field1, Field3 FROM tblGrips ORDER BY Field1

then the AfterUpdate event procudure would look something like this. Note: 
When you create a new module, you should see Option Explicit as the second 
line of code at the top of the module. If you do not see this, then head on 
over to this gem tip to re-configure your Visual Basic Editor (VBE) first:

    Always Use Option Explicit
    http://www.access.qbuilt.com/html/gem_tips.html#VBEOptions


Option Compare Database
Option Explicit

Private Sub cboRepairType_AfterUpdate()
On Error GoTo ProcError

   Me.txtSellPrice = cboRepairType.Column(1)


ExitProc:
   Exit Sub
ProcError:
   MsgBox "Error " & Err.Number & ": " & Err.Description, _
          vbCritical, "Error in procedure cboRepairType_AfterUpdate..."
   Resume ExitProc
End Sub


Make sure to compile your code before attempting to test this functionality. 
From within the VBE, click on Debug | Compile {ProjectName}

You will know immediately if you have a compile error. If the option becomes 
unavailable (ie. greyed out) then this is a good sign. It means that your 
code compiled without an error.


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

"Sandy" wrote:

> On my form I have a combo box (cboRepairType) which retrieves its list from 
> field(1) of tblGrips. Once the selection has been made (AfterUpdate I 
> presume) I would like the corresponding value from field(3) of tblGrips to 
> display in a text box (txtSellPrice), (or would another type of display be 
> more appropriate?)
> Can this be done?
> 
> Please be gentle I am a novice at this :-)
> Sandy
0
Utf
11/20/2007 9:07:02 PM
Thanks Tom,

I don't have time to try it at the moment but I will let you know how I go.
Your explanation does seem easy to follow so hopefully it will be a breeze.

Thanks again in the interim.
Sandy

"Tom Wickerath" <AOS168b AT comcast DOT net> wrote in message 
news:C1889A54-BD40-4AD7-A318-767DAFA787D5@microsoft.com...
> Hi Sandy,
>
> Yes, it can be done. Use the Afterupdate event procedure, as you have
> indicated. In VBA code, the columns are "zero-based", so the first column 
> of
> the rowsource would be column(0), the second column would be column(1), 
> etc.
> You must include the the corresponding value from field(3) in the 
> rowsource
> for your combo box. So, for example, if field(3) from the table was the
> second field in the rowsource, ie.
>
> SELECT Field1, Field3 FROM tblGrips ORDER BY Field1
>
> then the AfterUpdate event procudure would look something like this. Note:
> When you create a new module, you should see Option Explicit as the second
> line of code at the top of the module. If you do not see this, then head 
> on
> over to this gem tip to re-configure your Visual Basic Editor (VBE) first:
>
>    Always Use Option Explicit
>    http://www.access.qbuilt.com/html/gem_tips.html#VBEOptions
>
>
> Option Compare Database
> Option Explicit
>
> Private Sub cboRepairType_AfterUpdate()
> On Error GoTo ProcError
>
>   Me.txtSellPrice = cboRepairType.Column(1)
>
>
> ExitProc:
>   Exit Sub
> ProcError:
>   MsgBox "Error " & Err.Number & ": " & Err.Description, _
>          vbCritical, "Error in procedure cboRepairType_AfterUpdate..."
>   Resume ExitProc
> End Sub
>
>
> Make sure to compile your code before attempting to test this 
> functionality.
> From within the VBE, click on Debug | Compile {ProjectName}
>
> You will know immediately if you have a compile error. If the option 
> becomes
> unavailable (ie. greyed out) then this is a good sign. It means that your
> code compiled without an error.
>
>
> Tom Wickerath
> Microsoft Access MVP
> https://mvp.support.microsoft.com/profile/Tom
> http://www.access.qbuilt.com/html/expert_contributors.html
> __________________________________________
>
> "Sandy" wrote:
>
>> On my form I have a combo box (cboRepairType) which retrieves its list 
>> from
>> field(1) of tblGrips. Once the selection has been made (AfterUpdate I
>> presume) I would like the corresponding value from field(3) of tblGrips 
>> to
>> display in a text box (txtSellPrice), (or would another type of display 
>> be
>> more appropriate?)
>> Can this be done?
>>
>> Please be gentle I am a novice at this :-)
>> Sandy 


0
Sandy
11/20/2007 9:14:51 PM
Sorry to take so long to come back to you Tom; the method you illustrate 
works fine.

Can I ask a further question?

How can the following code be adjusted to include the corresponding value 
from 'SellPrice' field in the combo box rowsource. And if possible to 
include the 'BuyPrice' so I can refer to that too in a similar fashion to 
the 'SellPrice' field. And would it work with the code you have already 
supplied?

tblGrips has three fields 'GripType', 'BuyPrice', 'SellPrice' other tables 
referred to in the 'Select Case' would be similar.

Private Sub cboRepairCategory_AfterUpdate()
    On Error Resume Next
        Select Case cboRepairCategory.Value
            Case "Grips"
                cboRepairType.RowSource = "tblGrips"
         *****Etc*****

                End Select
End Sub

I would like to keep all the 'Select case' tables as separate tables.
Hope this makes sense.

Sandy


"Tom Wickerath" <AOS168b AT comcast DOT net> wrote in message 
news:C1889A54-BD40-4AD7-A318-767DAFA787D5@microsoft.com...
> Hi Sandy,
>
> Yes, it can be done. Use the Afterupdate event procedure, as you have
> indicated. In VBA code, the columns are "zero-based", so the first column 
> of
> the rowsource would be column(0), the second column would be column(1), 
> etc.
> You must include the the corresponding value from field(3) in the 
> rowsource
> for your combo box. So, for example, if field(3) from the table was the
> second field in the rowsource, ie.
>
> SELECT Field1, Field3 FROM tblGrips ORDER BY Field1
>
> then the AfterUpdate event procudure would look something like this. Note:
> When you create a new module, you should see Option Explicit as the second
> line of code at the top of the module. If you do not see this, then head 
> on
> over to this gem tip to re-configure your Visual Basic Editor (VBE) first:
>
>    Always Use Option Explicit
>    http://www.access.qbuilt.com/html/gem_tips.html#VBEOptions
>
>
> Option Compare Database
> Option Explicit
>
> Private Sub cboRepairType_AfterUpdate()
> On Error GoTo ProcError
>
>   Me.txtSellPrice = cboRepairType.Column(1)
>
>
> ExitProc:
>   Exit Sub
> ProcError:
>   MsgBox "Error " & Err.Number & ": " & Err.Description, _
>          vbCritical, "Error in procedure cboRepairType_AfterUpdate..."
>   Resume ExitProc
> End Sub
>
>
> Make sure to compile your code before attempting to test this 
> functionality.
> From within the VBE, click on Debug | Compile {ProjectName}
>
> You will know immediately if you have a compile error. If the option 
> becomes
> unavailable (ie. greyed out) then this is a good sign. It means that your
> code compiled without an error.
>
>
> Tom Wickerath
> Microsoft Access MVP
> https://mvp.support.microsoft.com/profile/Tom
> http://www.access.qbuilt.com/html/expert_contributors.html
> __________________________________________
>
> "Sandy" wrote:
>
>> On my form I have a combo box (cboRepairType) which retrieves its list 
>> from
>> field(1) of tblGrips. Once the selection has been made (AfterUpdate I
>> presume) I would like the corresponding value from field(3) of tblGrips 
>> to
>> display in a text box (txtSellPrice), (or would another type of display 
>> be
>> more appropriate?)
>> Can this be done?
>>
>> Please be gentle I am a novice at this :-)
>> Sandy 


0
Sandy
11/22/2007 12:23:18 PM
Hi Sandy,

> How can the following code be adjusted to include the 
> corresponding value from 'SellPrice' field in the combo box
> rowsource.

Given that you appear to be using a table in the rowsource, ie. 
cboRepairType.RowSource = "tblGrips", both the sellprice and buyprice fields 
should be available. I suspect that you simply need to change a few 
properties for your combo box--increase the column count, and set the column 
widths appropriately, in order to see these fields. These properties are 
found on the Format tab of the Properties dialog. 

However, do you really want to specify a table as the rowsource? The reason 
I question this is that you may have difficultly achieving a list that is 
sorted properly. Generally, it is better to use a saved query or a SQL 
statement for the rowsource. This allows precise control over the sorting, 
using the ORDER BY clause.

> And would it work with the code you have already supplied?

Yes.

> I would like to keep all the 'Select case' tables as separate tables.

May I ask why?  Storing similar data in different tables is generally not 
considered good database design. You will likely be better off to have all of 
the data in one table, with an added field that describes the attribute that 
your table’s names are currently describing. Can you please expand on why you 
wish to segregate apparently similar data into separate tables? It would be 
helpful to provide examples of this other data.


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

"Sandy" wrote:

> Sorry to take so long to come back to you Tom; the method you illustrate 
> works fine.
> 
> Can I ask a further question?
> 
> How can the following code be adjusted to include the corresponding value 
> from 'SellPrice' field in the combo box rowsource. And if possible to 
> include the 'BuyPrice' so I can refer to that too in a similar fashion to 
> the 'SellPrice' field. And would it work with the code you have already 
> supplied?
> 
> tblGrips has three fields 'GripType', 'BuyPrice', 'SellPrice' other tables 
> referred to in the 'Select Case' would be similar.
> 
> Private Sub cboRepairCategory_AfterUpdate()
>     On Error Resume Next
>         Select Case cboRepairCategory.Value
>             Case "Grips"
>                 cboRepairType.RowSource = "tblGrips"
>          *****Etc*****
> 
>                 End Select
> End Sub
> 
> I would like to keep all the 'Select case' tables as separate tables.
> Hope this makes sense.
> 
> Sandy
0
Utf
11/23/2007 3:01:00 AM
Hi Tom

I thought separate tables would be easier because:

There would be five basic tables:-
tblRepairCategory
    with fields:- RepairCatID (Autonumber), RepairCategory (Text)
        values being - Grips, Loft and Lie, Reglue, Shafts.

tblGrips
    with fields: RepairType (Text), BuyPrice (Currency), SellPrice 
(Currency)
        typical values for Repair Type:- Gents A, Gents B etc.

tblLoftAndLie
    with fields: Repair Type (Text), BuyPrice (Currency), SellPrice 
(Currency)
        typical values for Repair Type:- Loft, Lie, Loft and Lie.

tblReglue
    with fields: Repair Type (Text), BuyPrice (Currency), SellPrice 
(Currency)
        typical values for Repair Type:- Graphite, Steel, Junior etc

tblShafts
    with fields: Repair Type (Text), BuyPrice (Currency), SellPrice 
(Currency)
        typical values for Repair Type:- Graphite S, Graphite R, Steel S 
etc.

I would also have a table for Customers (Usual stuff) and also for 
RepairJob.

Repair Job would contain the JobNo, Repair Category, RepairType, Number (of 
Units), BuyPrice, SellPrice, SubTotal, Discount, TotalCost. - SubTotal and 
TotalCost would be calculated fields.

Naturally there would be a few queries for data analysis.

I thought it would be easy to supply the combo boxes by having separate 
tables.

Your comments are appreciated.
Sandy


"Tom Wickerath" <AOS168b AT comcast DOT net> wrote in message 
news:68EA680E-D692-42D0-95F8-CC46E6DE5C08@microsoft.com...
> Hi Sandy,
>
>> How can the following code be adjusted to include the
>> corresponding value from 'SellPrice' field in the combo box
>> rowsource.
>
> Given that you appear to be using a table in the rowsource, ie.
> cboRepairType.RowSource = "tblGrips", both the sellprice and buyprice 
> fields
> should be available. I suspect that you simply need to change a few
> properties for your combo box--increase the column count, and set the 
> column
> widths appropriately, in order to see these fields. These properties are
> found on the Format tab of the Properties dialog.
>
> However, do you really want to specify a table as the rowsource? The 
> reason
> I question this is that you may have difficultly achieving a list that is
> sorted properly. Generally, it is better to use a saved query or a SQL
> statement for the rowsource. This allows precise control over the sorting,
> using the ORDER BY clause.
>
>> And would it work with the code you have already supplied?
>
> Yes.
>
>> I would like to keep all the 'Select case' tables as separate tables.
>
> May I ask why?  Storing similar data in different tables is generally not
> considered good database design. You will likely be better off to have all 
> of
> the data in one table, with an added field that describes the attribute 
> that
> your table's names are currently describing. Can you please expand on why 
> you
> wish to segregate apparently similar data into separate tables? It would 
> be
> helpful to provide examples of this other data.
>
>
> Tom Wickerath
> Microsoft Access MVP
> https://mvp.support.microsoft.com/profile/Tom
> http://www.access.qbuilt.com/html/expert_contributors.html
> __________________________________________
>
> "Sandy" wrote:
>
>> Sorry to take so long to come back to you Tom; the method you illustrate
>> works fine.
>>
>> Can I ask a further question?
>>
>> How can the following code be adjusted to include the corresponding value
>> from 'SellPrice' field in the combo box rowsource. And if possible to
>> include the 'BuyPrice' so I can refer to that too in a similar fashion to
>> the 'SellPrice' field. And would it work with the code you have already
>> supplied?
>>
>> tblGrips has three fields 'GripType', 'BuyPrice', 'SellPrice' other 
>> tables
>> referred to in the 'Select Case' would be similar.
>>
>> Private Sub cboRepairCategory_AfterUpdate()
>>     On Error Resume Next
>>         Select Case cboRepairCategory.Value
>>             Case "Grips"
>>                 cboRepairType.RowSource = "tblGrips"
>>          *****Etc*****
>>
>>                 End Select
>> End Sub
>>
>> I would like to keep all the 'Select case' tables as separate tables.
>> Hope this makes sense.
>>
>> Sandy 


0
Sandy
11/23/2007 7:46:02 PM
Hi Sandy,

> I thought it would be easy to supply the combo boxes by having separate
> tables.

Not really. It is just as easy to include the appropriate criteria in the 
WHERE clause of a SQL statement (or saved query), so that the appropriate 
records are selected. You will likely want to base the rowsource on a query 
in any case, so that you can apply an appropriate sort order. 

But here's just one example of where the difficulty comes in, by storing 
like data in separate tables: suppose you need to create a report, grouped by 
Repair Type, which includes all of the repair types offered. In this case, 
you will be forced into using a Union query, in order to join all the data 
back together again. Here is a tutorial on Union queries, in case you are not 
aware of this query type. It is on my personal web space, and was written 
several years ago by a co-worker at my place of work:

   http://home.comcast.net/~tutorme2/samples/unionqueries.zip

So, I think it would be best if you combined the data from tblGrips, 
tblLoftAndLie, tblReglue, tblShafts, etc. into one table. Add a new field to 
indicate the repair type. This can either be a text field, with values such 
as "grips", "loft", "reglue", "shafts", etc., or it can be a numeric field 
(Long Integer--->remove the default 0 value) that serves as a foreign key 
field for a new table, say tblRepairTypes, with an autonumber primary key.

If you go with the two table design, which is normalized better vs. a single 
table design, where repair types are broken out to a new table, you would 
likely want to have two combo boxes on your form: one to select the repair 
type, and the second (synchronized) combo box to allow the user to select 
appropriate records for the repair type selected in the first combo box. Here 
are a couple of tutorials on this subject:

    Limit content of combo/list boxes
    http://www.mvps.org/access/forms/frm0028.htm

    How to Synchronize Two Combo Boxes on a Form
    http://support.microsoft.com/kb/289670

Note: Disregard the "in Access 2002 or in Access 2003" part from the title 
of the second article, as the same logic applies to other versions of Access 
equally well.

Here is a link to various database design papers. This topic is very 
important that you gain a good understanding of, in order to have success 
using Access. I recommend at least reading the first two articles, by author 
Michael Hernandez:

http://www.accessmvp.com/JConrad/accessjunkie/resources.html#DatabaseDesign101


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

"Sandy" wrote:

> Hi Tom
> 
> I thought separate tables would be easier because:
> 
> There would be five basic tables:-
> tblRepairCategory
>     with fields:- RepairCatID (Autonumber), RepairCategory (Text)
>         values being - Grips, Loft and Lie, Reglue, Shafts.
> 
> tblGrips
>     with fields: RepairType (Text), BuyPrice (Currency), SellPrice 
> (Currency)
>         typical values for Repair Type:- Gents A, Gents B etc.
> 
> tblLoftAndLie
>     with fields: Repair Type (Text), BuyPrice (Currency), SellPrice 
> (Currency)
>         typical values for Repair Type:- Loft, Lie, Loft and Lie.
> 
> tblReglue
>     with fields: Repair Type (Text), BuyPrice (Currency), SellPrice 
> (Currency)
>         typical values for Repair Type:- Graphite, Steel, Junior etc
> 
> tblShafts
>     with fields: Repair Type (Text), BuyPrice (Currency), SellPrice 
> (Currency)
>         typical values for Repair Type:- Graphite S, Graphite R, Steel S 
> etc.
> 
> I would also have a table for Customers (Usual stuff) and also for 
> RepairJob.
> 
> Repair Job would contain the JobNo, Repair Category, RepairType, Number (of 
> Units), BuyPrice, SellPrice, SubTotal, Discount, TotalCost. - SubTotal and 
> TotalCost would be calculated fields.
> 
> Naturally there would be a few queries for data analysis.
> 
> I thought it would be easy to supply the combo boxes by having separate 
> tables.
> 
> Your comments are appreciated.
> Sandy
0
Utf
11/24/2007 3:32:00 AM
> or it can be a numeric field 
> (Long Integer--->remove the default 0 value) that serves as a foreign key 
> field for a new table, say tblRepairTypes, with an autonumber primary key.

I see now that the above sentence should have read:

or it can be a numeric field (Long Integer--->remove the default 0 value) 
that serves as a foreign key field for your existing tblRepairCategory table, 
with an autonumber primary key.
 

Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

"Tom Wickerath" wrote:

> Hi Sandy,

<snip>

> So, I think it would be best if you combined the data from tblGrips, 
> tblLoftAndLie, tblReglue, tblShafts, etc. into one table. Add a new field to 
> indicate the repair type. This can either be a text field, with values such 
> as "grips", "loft", "reglue", "shafts", etc., or it can be a numeric field 
> (Long Integer--->remove the default 0 value) that serves as a foreign key 
> field for a new table, say tblRepairTypes, with an autonumber primary key.

0
Utf
11/24/2007 3:44:00 AM
Got it working Tom - Many thanks for your expertise and patience.
Sandy


"Tom Wickerath" <AOS168b AT comcast DOT net> wrote in message 
news:04BA9E9A-F9BC-4F85-931A-8CE2131779D4@microsoft.com...
>> or it can be a numeric field
>> (Long Integer--->remove the default 0 value) that serves as a foreign key
>> field for a new table, say tblRepairTypes, with an autonumber primary 
>> key.
>
> I see now that the above sentence should have read:
>
> or it can be a numeric field (Long Integer--->remove the default 0 value)
> that serves as a foreign key field for your existing tblRepairCategory 
> table,
> with an autonumber primary key.
>
>
> Tom Wickerath
> Microsoft Access MVP
> https://mvp.support.microsoft.com/profile/Tom
> http://www.access.qbuilt.com/html/expert_contributors.html
> __________________________________________
>
> "Tom Wickerath" wrote:
>
>> Hi Sandy,
>
> <snip>
>
>> So, I think it would be best if you combined the data from tblGrips,
>> tblLoftAndLie, tblReglue, tblShafts, etc. into one table. Add a new field 
>> to
>> indicate the repair type. This can either be a text field, with values 
>> such
>> as "grips", "loft", "reglue", "shafts", etc., or it can be a numeric 
>> field
>> (Long Integer--->remove the default 0 value) that serves as a foreign key
>> field for a new table, say tblRepairTypes, with an autonumber primary 
>> key.
> 


0
Sandy
11/24/2007 6:43:35 PM
Hi Sandy,

You're very welcome. Good luck on your project!


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

"Sandy" wrote:

> Got it working Tom - Many thanks for your expertise and patience.
> Sandy

0
Utf
11/24/2007 7:08:00 PM
Reply:

Similar Artilces:

Filtering a combo box using a combo box
All, I am trying to filter the records from a table displayed in a combo box using a combo box on the same form. I built a query and set the criteria as Me![FormName]![Combo_box]. This allowed me to filter the list, but it did not do exactly what I wanted. When the first combo box is blank, the second one is also blank. Is there anyway I can get the second combo box to display all of the records when the first box is blank? Thank you for your help. Regards, John Try a criteria in the second combo of: Like Forms!YourFormName!Combo1Name & "*" -- Arvin Meyer, MCP, MVP http:/...

Macro to add text to a Message
Hi all, Although I have used VBA in Excel, I have never used it in Outlook. Using Outlook 2007, What I would like to do seems simple enough but I have no clue how to do it. All I want to do is add text to the body of a message. I thought something like this would work but I get the error message "Sub of Function not defined". I know I'm missing an event or something but I'm not sure. Can someone please help? Sub APPRVL_REQ_TEXT() Dim Aprvl_Text As String Aprvl_Text = "Your approval is requested for the following contract renewals. Please a...

Command Button Text Resizes
I have Office XP on a Windows XP OS. For some reason, the text on my command buttons, when clicked by the user, decreases in size on each subsequent click. until it is very teeny. What is happening and how can I fix it? ...

Combo Box on Forms
Hi, I am using a combo box on a form that has several items w/ one being Other. If the user selects other I want them to be able to input what they want so that it will go into the table instead of just the "Other". I just am not really sure on how to do that. Can you help? Thanks, Jaime In design view click on VIEW - Properties and the the combo. Then change Limit To List to No. -- KARL DEWEY Build a little - Test a little "jseger22@yahoo.com" wrote: > Hi, > > I am using a combo box on a form that has several items w/ one being > Other. If the use...

convert number to text #4
How can i convert a number to text format without then editing that cell to force the cell to except the format change. I need a numbers to convert to text because a download from another program is already in text format with SS# in the cell. Then using at templet sheet with a VLook Up formula to pull information off the first workbook. To convert number to text, select the area you want to convert, right-click on format cells and choose "text". "RayG" wrote: > How can i convert a number to text format without then editing that cell to > force the cell to ex...

Combo Boxes
Someone sent me an Excel document where each of the cells in I1:I312 are combo boxes. When you click off of those cells, the down arrow disappears. The list for the combo boxes are cells AA1 and AB1 (AA1 is New and AB1 is Existing). Please explain how this was done? Also, can you please tell me if it is possible to make New and Existing autocorrect entries. So even though the choices are New and Existing, if you hit N, New appears, and if you hit E, Existing appears. Thanks!! It sounds like Data|Validation. Take a look at Debra Dalgleish's site: http://www.contextures.com/xlDataVa...

recurring Windows Configuration box appears since installing Publisher 2007
I am very frustrated with this problem and hope someone can help. Ever since I installed Publisher 2007, I have been having trouble with my Outlook 2003. I was not happy with the entire suite of programs on Office 2007 Enterprise but since I had already designed my business cards with Publisher 2007, I needed to load it on my desktop. (My Office 2003 version didn't include Publisher). Ever since installing the Publisher, from time to time when Outlook (2003) downloads email, a windows installer box appears saying it needs to configure Office Enterprise 2007; the dialogue box says "...

How to write text file
Hi, How to wrote a field (memo) content to a text file. Before write to text file I want to remove the <div> ,</div>. How to do that? SF "SF" <samnangs@pactcambodia.org> a �crit dans le message de news:ugsp$9dgKHA.1652@TK2MSFTNGP05.phx.gbl... > Hi, > > How to wrote a field (memo) content to a text file. Before write to text > file I want to remove the <div> ,</div>. How to do that? > > SF >parler francais ou espagnol Hi SF, Are you using Access 2007, with the .accdb file format, and a rich text fo...

New Excel Comment Box Issue
My Excel comment boxes are showing up as a solid black box. On the surface, it looks like the same issue as all the other posts that I have read. I'm running Office 2000 on Windows 2000 desktop. This has suddenly stopped working in the past week or so. I'm having problems with all spreadsheets with comments. I can access the spreadsheet on different computers without problems - all with the same setup. I have tried the following to no avail- Reinstalling Excel (2000) Checking the settings for the comment boxes - my settings are fill color: automatic style is set to 3/4 pt ...

= Text formula problem
Hi Everyone, I am using an excel spreadsheet as a linked table in an access database for an update query. I had it working very nicely for a period of time. I am not sure if some Microsoft update caused a problem or what. The field I use t o update my database didn't work until I used this formula to make a new row. I have a column of numbers which was retrieved from a data miner program it's called Acct. For some reason Access doesn't like the formatting so I insert a blank column to the right and call that PtNum. In the first cell of this column which is C2, I type ...

Edit box should support languages like japanese,chineese etc
Hi wht im trying to ask is.. 1. In my application, all the labels r in english only. 2.If i change the content of one text box in japanese or chineese language , [Text box value is the title for another dialog] 4.After i changed the content, i want the title to be displayed in japanese or chineese language. Note: I want only that text box to be changed ,,not the entire application.. so How can i able to support multibyte characters in MFC controls CEdit --text boxes.. Plz reply They do. You have to be in a Unicode app, and you have to have selected a Unicode font that has Chin...

Separator in combo box
hi, Is it possible to have a line separator in a combo box? I mean something like a separator in menus? thanks, Behzad Try :- http://www.codeproject.com/combobox/zsepcmb.asp http://www.codeproject.com/combobox/customcombo.asp -- Regards, Nish [VC++ MVP] http://www.voidnish.com /* MVP tips tricks and essays web site */ http://blog.voidnish.com /* My blog on C++/CLI, MFC, Whidbey, CLR... */ "behzad" <b@b.com> wrote in message news:%23fVB3em5EHA.3368@TK2MSFTNGP10.phx.gbl... > hi, > Is it possible to have a line separator in a combo box? I mean something > like...

Text boxes on graphs
How do you make a text box hide the grid lines behind it on a graph? The grid lines are still visible and run through the text box, cluttering it up. Thanks right-click text box choose -- 'Format Text Box' from shortcut menu colors and lines tab change fill color to white Warm Regards, Crystal remote programming and training Access Basics 8-part free tutorial that covers essentials in Access http://www.AccessMVP.com/strive4peace * (: have an awesome day :) * Drew wrote: > How do you make a text box hide the grid lines behind it on a graph? The > grid line...

convert text to Date..
How can I convert my text field ( read from CSV file) to show the Date as 01/05/2010 instead of long date.. Can I use CDate()? rundate =Tuesday, January 05, 2010 12:45:11 I used the following.. 'Dim date_tested As Date 'date_tested = Format(rundate, "Short Date") 'date_tested = Format(rundate, "mm/dd/yyyy") Thank you -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/Forums.aspx/access-formscoding/201001/1 Try this -- 'date_tested = Format(CVDate(run...

Multiple Combo Boxes Highlighted
Hi, I have a problem with something in VB6. I have 4 combo boxes with individual names (not an array) located on an SSTab object. When I select another tab and then return to the tab these boxes are located on, each of them appears to be highlighted in blue. I add values to them only when loading the form so I'm at a loss as to why this happens ? Any ideas are greatly appreciated. Thanks, Jen. "Jennifer Ward" <jward@comcast.net> wrote in message news:eq5HrcBrKHA.6064@TK2MSFTNGP02.phx.gbl... > Hi, > > I have a problem with someth...

Automatically inserting text into cells which already contain text
Version: v.X Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel I need to insert a particular text into the same selected cells in 145 separate rows. The selected cells already have text within them and I need to insert the new text at the beginning of each cell without damaging the text already in the cell. One way to do this is to use the ampersand as follows: <br><br>if A1 = dogs, then in B1 enter: <br> =&quot;Cats and &quot;&amp;A1 <br><br>This will result in B1 being equal to: <br> Cats and dogs <br><br>So ...

HELP !! Combo box to feed other combo boxes
Hi, I have a form with a stock list. One field is [Dealer Allocated] so stock can be allocated to a specific dealer - this is a combo box (combo1) for single allocations. I now also want to be able to update this combo box for several records in bulk. I thought I would do this by having a second combo box in the footer of the form which the user selects the dealer from and then clicks a button which looks for first record without dealer allocated and updates the value of combo1 to the value of combo2. This would then be enclosed in a Do Loop for specified number of records. I can...

Opening a text file in excel
Using a visual basic 6.0 I have created a tab delimiated text file, which is an export of a Query. I what to then open this file automaticly after it is created in Excel. I've looked about and can't find anyone with a simple answer. Most questions involve macros but I'm working from a vb application to excel. How do I open Excel? Dim xlTmp As Excel.Application Set xlTmp = New Excel.Application xlTmp.Workbooks.Open Fname$ I have tried the following but I get the error message: "User-defined type not defined" Fname$ Contains the path of the text file. ...

text box margin settings
I've changed the text box margins, saved the file and closed the file. But when I reopen the file, the changes are not there. What gives?!? don The text box margins in an EXISTING text box have changed? Brian Kvalheim Microsoft Publisher MVP http://www.kvalheim.org >-----Original Message----- >I've changed the text box margins, saved the file and >closed the file. But when I reopen the file, the changes >are not there. What gives?!? > >don >. > This issue is unknown in Publisher any version. If you mean it is not saving the defaults on next Text F...

Populate field based on combo box
I know this shouldn't be so hard - but I'm having a brain ... or something! On a form, I would like to select a District Number from a combo box and have the District Name appear in a text field. My form is based on a query. I know somehow I need to add criteria to my query to point to the info in the combo box but I'm not sure exactly where to put this criteria. Should the combo box field for the District Number on the form be based on the Districts table or is this the field that comes from the query? Or is it the District Name field that comes from the query? I have neve...

Flag box
Is it possible to add some flagbox in a column? How? Thanks Rossella Depends on what you mean by a flagbox. If you mean some sort of indicator, you could put Y or N in a column (X or leave empty??) and use data|filter|autofilter to "flag" certain entries. Rossella wrote: > > Is it possible to add some flagbox in a column? > How? > Thanks > Rossella -- Dave Peterson I meant the square with the x on it ..sorry if my explanation wasn't enough I find this technique pretty easy... Select the range Format|cells|number tab|custom category In the "type:&qu...

How drop a text file?
I'm designing the error logic for a VB2005 console application that reads Excel files from a folder, one at a time, and writes a text file for each when called by a script. I'm using streamwriter to write the text file. If I trap an error and want to throw the text file away cleaning up all the associated resources, how do I do that? I reviewed MSDN on streamwriter's methods but none looked promising. The closest was dispose, but I had trouble understanding the article and it didn't feel right. Please be patient if I don't reply promptly. I am not getting...

Problem with Wrap text
I have a problem with wrap text in merge cells. when the cell is formatted (single cells) everiting is OK. When the merge cells is formatted (three cells in one merge cells) it is not OK. I must manually change height of the cells :( Please help Srdjan I get the same result! It may just be a bug in XL. I even tried merging the cells AFTER formatting them, and that didn't make any difference. I also un-merged the cells, and the word wrap was fine, but on re-merging them it was just like before. I don't know if there IS a solution! <srdjan.radnovic@gmail.com> wrote in message ...

combo
have placed a subform, which gives the Price. It is based on the Query. I have given a criteria in the query like [forms]![mainform]![productid]. So, when I select a product from a combo box, on the main form, I should see the price on the subform. The problem, is it does not refresh. It still shows the same price for the earlier product. But, when I move, it gets refreshed. Can I have a code , so that I should see the price as soon as I select the product from the combo box . On the After Update event of your combo box put the following: [Forms]![frmMainForm]![sfrmSubfo...

combo box
Hi: I have a combobox which shows two values: name and age, after I choose "the value", the combo box just shows the "name". I need to be able to print both values. How can I tell the combo box to leave the 2 fields onscreen? Hello Gabito, You can only display one column in the Combo Box. Is this Combo Box on a worksheet? If so, the TextColumn is the one that is displayed and the BoundColumn is the value returned by the combo box. You could make the TextColumn 1 (Name) and the BoundColumn 2 (Age). Then set the Linked cell to an adjacent cell just to the ri...