ms-access-2010

How to convert a text field in an Access table to a rich text memo using VBA

故事扮演 提交于 2019-11-28 02:17:16
My users have a number of backend .accdb databases (which I can't access directly). I need to code some vba to modify the structure of some of the tables in these databases to convert Text Fields to Rich Text memos. (The fields already contain text including Access "rich-text" i.e. the relevant html coding). I need to: Modify the field to be a rich text memo. Modify the existing contents (if applicable) to display correctly as Access rich text in forms, datasheets and reports. I can write a SQl statement that will modify a field from TEXT (255) to MEMO: ALTER TABLE tblSource ALTER COLUMN

Navigating to a different tab in navigation subform

会有一股神秘感。 提交于 2019-11-28 01:42:11
问题 In an ms access 2010 database, I have a listbox whose afterupdate procedure needs (among other things) to navigate to a specific tab in a navigation subform. I can get it to change the SourceObject property of the navigation subform, but the selected tab does not get changed, so the user ends up seeing the right source object with the wrong tab selected. This looks unprofessional. How can I change both the selected tab and the source object? I uploaded a simplified database that recreates the

Automatically generate Date + 4-digit sequence number for ID in Access 2010+

耗尽温柔 提交于 2019-11-28 01:32:27
I need to automatically generate a 12 character value for my Business Key. Without any user interaction. 8 character -> Today Date (yyyymmdd or ddmmyyyy). + 4 character -> Sequential Number (0001,0002,0003). The Sequential Number must reset on each new day. Is it possible to do this in Microsoft Access 2010+ without any coding involved? Since you are using Access 2010+ the best way to accomplish your goal would be to use a Before Change data macro like this To create the Before Change macro, click the "Before Change" button on the "Table" tab of the ribbon when the table is open in Datasheet

How to insert values into the database table using VBA in MS access

Deadly 提交于 2019-11-28 01:10:08
问题 I've started to use access recently. I am trying to insert a few rows into the database; however, I am stuck as it is throwing an error: Too few parameters. I have a table test with only one column in it named start_date I want to insert all the dates between two dates for example if I consider 1/7/2014 to 3/7/2014 I need dates as 1/7/2014,2/7/2014,3/7/2014 in my table, but I have problem inserting the code I used is as follows Private Sub createRec_Click() Dim StrSQL As String Dim InDate As

Prevent enabling of shift bypass - Access 2010

隐身守侯 提交于 2019-11-28 00:35:47
I am trying to prevent database users from being able to view the linked tables in the navigation pane of an Access 2010 database. I have hidden the pane and disabled the F11 key. I am aware that you can disable the functionality of the SHIFT key that permits you to bypass the access start-up options as per this article . My question is whether it is possible to prevent a user from re-enabling the shift key either from within the database itself or remotely via another database. If this is not possible does anyone know of the next best method I can use to prevent users viewing the tables in

How to install visual studio 2010 setup project with MS Access database on a computer which is not having Office 2010 installed?

半腔热情 提交于 2019-11-28 00:26:57
I am developing wpf application in C#. I have successfully created the setup project for wpf application in visual studio 2010. I have used MS Access 2010 as a database. It install fine on all computers. But on some computer there is no Microsoft Office installed and on some computer there is lower version of MS Office like MS Office 2003. When I install my application on these computers it gives me connectivity issues. Can you please tell me what should I need to do ? Should I need to include any prerequisite for MS Access 2010 in visual studio 2010 setup project ? If there is any which are

how to export Access 2010 data macros

喜欢而已 提交于 2019-11-27 23:11:26
I need to transfer Access data macros from my test db to my production db. Anybody know how to do that? I know that transferring tables from one accdb to another will also transfer the data macros, but that's not an option in my case. I also know I can recreate them manually in the production accdb, but that leaves me open to errors and requires taking the production database down for a longer time than would a scripted transfer scenario. If I only had to do this once it wouldn't be such a big deal, but I'll need to do it many times over the course of a development project. I've tried

Repeat records according to a quantity field

早过忘川 提交于 2019-11-27 23:03:16
问题 I have an Excel sheet which I receive from my customer and I get imported to Access and I would call that table [tblCustomer] and that would look something like this: ProductID Name Expire date SumofQty ------------ ----------- --------------- -------- 3 Flour 13-Dec-2013 6 6 Meat 20-Jan-2014 10 So the table contain maybe 100 items. I want in the same table or another table to copy the same record 6 times as per SumofQty and than the next record copy it 10 times and so on. I need this cause I

Excel ADODB VBA error msg 'Not a Valid Password'

馋奶兔 提交于 2019-11-27 19:31:10
问题 I am trying to open a Connection to Password protected AccessDB, through Excel VBA. I am using the following connection string conn.Provider = "Microsoft.ACE.OLEDB.12.0" conn.ConnectionString = "Data Source=dbPath; Jet OLEDB:Database Password=pwd;" where dbPath is the path of accdb/mdb file and pwd is the password to the dbfile. The password is absolutely correct but I am always getting the error "Not a Valid Password". Could someone please guide me in this?? -Sri. Additional Info: I am using

Make fields visible in MS Access form as certain fields are completed

会有一股神秘感。 提交于 2019-11-27 18:41:24
问题 I am building a form In MS Access for users to input data but there are too many possible fields. Most of the time only about half the fields will be used. I thus would like to have certain fields appear only depending on what the user inputted on a prior given field. Ex: user enters project number, title, then he checks a "yes/no" engineering. since he checked it this means engineering is impacted so a dozen fields that the user will have to fill out appear. Is this possible: 1)without VBA 2