I have a field that contains an IP Address. The ranges vary significantly meaning some of the octecs have 3 characters and some have 1 or 2. Example; 100.2.25.250 and the next record may be 1.20.25.251. I need to add a "/32" to the end of the IP Address. How can I automate this for all the records? I know I can create an update query, but I'm not sure how I can do this. However, I will say for most of the records the IP Address is the only thing in the field. Some of the fields have multiple IP Addresses.
I have to tables, where if data in one field is in both tables I don't want the row to be shown in my query. I have triede with a IIf sentence, but I can't get it to work.
I have a list of jobs for a report in which there are multiple jobs per page. When there is a page break in the report some jobs are being cut off and then started on the next page. I do not want any information from a job to be seperated by a page break. I just want a page break to occur after a full job listing. I don't mind if the page is short, just don't want any jobs broken up. Is there a way to accomplish this??? Thanks.
I have a database with a form and a sub form it works great. However I needed to add a tab or page to the sub form when I returned to the form view the sub form is there but you cant see anything. change back to design view and its there. I didn't change any properties on the sub form. and If I delete the page I added it works just like it did before I added it. also the sub form is linked to the main form master and child. would I have to link the tab also??
I have two tables that need to be updated in tandem from a single access-page, by entering previously non-existent data. One contains a contractor ID, and the name of the contractor; The other contains details of contracts, with the name of the Contractor selected from a drop-down box that draws its contents from the other table.
I have a data access page with an always visible drop-down box that shows contractors, and if I select one, it displays all contracts entered. This unfortunately means I cannot easily add new contractors, since they have no pre-existing contracts to display the details, and allow entering, and I cannot make the details fields permanently available.
Right now, I can add new contracts to those contractors who have at least one in the system already, but I'm unable to add new contractors. My aim is to have a single page add the contract data, and new contractors. Having a hyperlink open a new page that allows the adding of new contractors is also acceptable, but no coding, please, cause I suck at that...:(
I would like to add a page to a tab form when a certain button is clicked. I don't want to use the visible/hide solution. So I already found out that this can only be done in design view. I am using the following code:
Code:
Private Sub cmd_StrategyAdd_Click() DoCmd.OpenForm "Form1", acDesign Me.tabMain.Pages.Add DoCmd.OpenForm "Form1", acNormal End Sub
I am getting the error: Run-time error 2467. The expression you entered refers to an object that is closed or doesn't exist.I am sure the name of my tab form is tabMain.
I have small database in ms access which i am using for invoice creation. When invoice is created i save it as PDF. I would like merge another single Page PDF along with the report as 2nd page so end report is 2 page PDF.
Second how can i get 1 PDF from 2 ms access reports.
What I am trying to do is split a sentence into words LikeJocelyne Labylle And Jacob DesvarieuxThis would produce 4 words as the and,&,/ Ect are removedSo I end up with:-JocelyneLabylleJacobDesvarieuxIf all 4 words are found in a string it returns all matching records plus gets 100%3 words again returns all matching records plus say 75% and so onI haven't done a lot with it at the min as the first bit is quite simple IE getting the names Etc. but I can't think for the life of me how I can do the search.I Have Tried a query With [Names] Like ""*[String Names]*""" but it seems to only work with each letter???but my main reason for asking here is I don't like reinventing the wheel or at least trying to which will mean hours of Fun but maybe somebody knows of something I could use on the net.Thanks for any help/Advice.mick
I would like to create a table containing email templates for use around various applications and interfaces. I would also like the user to be able to create the text for these templates, but as well as the dynamic text. So a user might create a record as such:
Email_Template_ID: 1234 Email_Name: "Payment notification" Email_Subject: "Project ID: {Project_ID} - Payment made" Email_Body: "Dear {Title} {Surname} We have recently made a payment of {Amount}. Please check your bank account in the next two days. This relates to Project ID: {Project_ID}, {Project Name}. Best wishes Payment Team"
So a user, with sufficient knowledge of certain field names, would be able to drop in the dynamic content as they deem appropriate. The VBA would then replace anything in curly brackets with the genuine field name.
I could possibly start with Replace(Email_Body, "{", "' & [") and repeat it for the end curly bracket, but I'm sure VBA would just render this as Dear ' & [Title] & ' etc. without interpreting it as Dear Mr...
I hope I've explained myself OK. To look at it another way, in Excel there is a function called INDIRECT() which allows Excel to interpret a cell reference as the actual content of the cell...
I have info on my access form which is located here....
Code : Forms![Front Page]![Site 2 Owner]
and here
Code : Forms![Front Page]![Postcode S2]
I would like to export this information into cells B2 & C2( individually and respectively) on the excel spreadsheet which I have saved as a template here...
Code : C:UsersmedesktopAutoExcel Auto
Is this easily achievable? To be honest I will be using it to fill in about 12 cells but how it would be done for the first two i can just modify it as necessary.
I created a form with lots of conditional formatting that did pretty much everything I wanted it to do. The only problem is that it takes about 4 full minutes for the form to open.
As an experiment I am reluctantly now trying to display the results in Excel. I have created a template xls sheet and all I want to do is, on the press of a button, copy the results from my query and paste them in to cell a1 of my spreadsheet.
I found the following code online which I am trying to adapt.
Code: Private Sub update_tracker_Click() Dim XL As Excel.Application Dim wbTarget As Workbook Dim qdfResults As QueryDef Dim rsResults As Recordset 'Set up refernce to the query to export
[Code] ....
My limited knowledge however results in a couple of errors.
The first error User defined type not defined error appears at the very first line of my code
Code: Dim XL As Excel.Application
The next error occurs as I am not sure how to reference the query to export. The query is called 2014 Resources and outputs also to a form called 2014 Resources.
I'm using the below to merge an access form into a word template (it's a starter for 10).
That works fine. What I need to do is save the word template as HTML so I can then upload it to my website.
Dim wordApp1 As Word.Application Dim docPath1 As String Dim fileName1 As String Dim PageName As String PageName = Forms!Frm_Page_Create![Page] docPath1 = Application.CurrentProject.Path & "Merges"
I am modifying an existing form that has some tabbed pages(subforms) in it and I am wanting to know how to add another page. I have created another subform that I am wanting to add to this main form as another tabbed page.
I'm working on a pretty serious report (at least for me)...I have 3 sub-reports inside, and the point of this is to use VBA and loop through several conditions (in the underlying queries), and print out in a batch for the user. When I add a page number footer it adds about 3 seconds to the processing time for a 14 page report. That doesn't sound like a whole lot, but when I loop through and process this 12 times, that's a lot of added time for the user...(the last thing I want to hear is it's slow!)
So, would it be faster if I set the page numbers in VBA? What event would I use? On Load?!? Also, how would I find the page number variables in VBA?
I should find the position of a number in a sentence and later extracted. The number is attached always to an "E". ie: E1, E2, E3,E4. The range of the number is 1-4. I have this until now:
I am able to use DoCmd.TransferSpreadsheet to export data from Access to Excel, however, I want to be able transfer data into a specific sheet within an Excel template (e.g. Tasking.xls), that will then save under a different name (e.g. Tasking 20140429.xls). The other sheets within the Excel template contain pivots etc. so they will need updating during this process. The Excel template should just close down and remain in its original format.
This process will occur once a week so the dates will have to change accordingly.
Any definitive way of exporting a query to an Excel file and then saving it as a new file without saving over the original.
I've tried to remove any confidential info from the code below so it's not exactly the same.
Code: Dim XLApp As Excel.Application Dim XLSheet As Excel.Worksheet Dim tmpRS As DAO.Recordset Dim strFolder as String strFolder = ("C:Profiles"& [Name] & "")
[Code] ....
The error seems to be with the SQL statement although that may just be the first error that it got to. I read that you can't refer to a Query if it has a criteria and that you have to write the SQL directly into the code.
I'm doing a project for my work. I created a few reports in Access. Some of these reports are simple graphic bars. How can I insert these reports into a word document template?
I have this UDF in my excel template that changes a set of numbers in to letters corresponding a code.
For example the code is "EUCHARISTO" it would simply mean
E=1, U=2, C=3, H=4, A=5, R=6, I=7, S=8, T=9, O=0 and by default the tenths position (".0")=X the hundredths position (.0"0") = Y and If a number repeats it becomes G.
Function LetterCode(ByVal Numbers As String, Letters As String) As String Dim X As Long Numbers = Format(Numbers, "0.00") * 100 Letters = UCase(Right(Letters, 1) & Left(Letters, Len(Letters) - 1)) If Numbers Like "*0" Then Mid(Numbers, Len(Numbers)) = "Y"
[Code] ...
Also, where best to put this code, In a query or in a module.
I have a few problems and I want them to be able to be done from switchboard:
1. Is there a way for me to export a particular report (after selecting it) to a closed excel template, that is formatted? It would open the excel template (that has a logo and column headings), export data to below the column headings, then save the file with a unique name?
2. Also, a way to import data from an excel file, after allowing the user to select file? Only data below the column headings mentioned above. Same data will be appended to existing table.