Forms :: Show Image / Text / Xlsx File In Continuous Subform
Jul 12, 2015
I want to show an subform where in I would like to display images,txt,xlsx that are stored in a directory as icons which when clciked would open the respective files.The info related to the images are stored in t_CustomerFiles.
Record ID, CustomerID, DestinationPath,EventFileName,
1, A, C:UsersTestDesktopCustFiles, CustA1.jpg
2, A, C:UsersTestDesktopCustFiles, CustA2.xlsx
3, B, C:UsersTestDesktopCustFiles, CustB1.txt
4, C, C:UsersTestDesktopCustFiles, CustC1.jpg
5, C, C:UsersTestDesktopCustFiles, CustC2.jpg.
I would like to show them on a continusous sub form .. I am using image control by setting its control source property but it does not seem to work..Do I need something else for the xlsx and txt files..
View Replies
ADVERTISEMENT
Oct 29, 2014
I have continuous form in Access 2010 and I would like when user will click on record, the image, for instance, imgTest become visible for that record. But for other records the image not visible. How it to do?
View 6 Replies
View Related
Jan 9, 2014
I have a continuous subform which queries a table of attachments. I'm using Access 2007 but not using the Attachment datatype; this DB will grow considerably and I don't want to waste precious space by filling it with bulky files. So instead, I have code which makes a copy of the attachment and adds the hyperlink (to the copy) to the table instead.
Now - I want to add a control to the subform to display an icon / image reflecting the file type of the attachment (Word doc, Excel s/s, PDF etc.)
But not sure how to go about it.
I was thinking I could use FileSystemObject.GetFileExtension at the point in the code where the attachment is added, and add a new field to my attachments table (i.e. translate "*.xls*" to "Excel", etc.) Then store / embed a handful of images for the core types I would expect and use an image control on the subform to display the image based on the value of that field.
But is that even possible / feasible?
Or, is there a handy API which can retrieve the icon associated with a file type based on what has been installed on the local machine (even if there is, there's still the problem of setting up the image control to display the appropriate icon specific to each record...)
Or, is there another control available which would be better suited to something like this than an Image control?
View 4 Replies
View Related
Aug 15, 2013
I would like to add image to list box but i read somewhere i have to use continuous sub form instead.
Now i like to know in sub form also we can select multi items and it shows highlighted entire of each row and easily getting value if selected items.
View 4 Replies
View Related
Jun 24, 2015
I have a continuous subform with an unbound Concat textbox and would like to populate another field for each record with the results with a main form button onClick event.
How do I accomplish this?
View 2 Replies
View Related
Apr 2, 2015
I have a continuous subform which essentially comprises of a textbox that shows a field from a query.
The text in that box is essentially a few letters and a few numbers - what I am wondering is if I can have an on click event for the textbox, that when a user clicks the text it takes them to the record (in a different form) that matches the text contained in the textbox they clicked?
View 1 Replies
View Related
Mar 17, 2014
I am trying to use a Connection to an xlsx spredsheet to read in a table of information (the data is not a table, just laid out in a table, see attached, the one I am trying to load is xlsx not xls but I cannot for some reson upload the xlsx one on here)
I have the following declared:
Code:
Dim cn As ADODB.Connection
Dim rs As ADODB.Recordset
my connection string is:
Code:
strConnectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" & cstrFolder &
Chr(92) & tempSymbol & ".xlsx;Extended Properties='Excel 12.0 Xml;HDR=YES';"
I open the connection which works fine:
Code : cn.Open strConnectionString
Now here I hit the problem, I have the following SQL string:
Code : strSelect = "SELECT * from [table$]"
The spreadsheet contains just 1 tab, named table so I think I am referring to the data correctly in my SQL string?
When I open the recordet for variable rs using:
Code : rs.Open strSelect, cn, adOpenStatic, adLockOptimistic, adCmdText
I get the error dialogue box:
The Microsoft Access database engine could not find the object 'table$'. make sure the object exists and that you spell its name and the path name correctly.....
I did a Debug.print to check the strConnectionString was correct and the Source is exactly correct and refers to the name of the file I am trying to access exactly.
View 2 Replies
View Related
Aug 17, 2006
Good morning everyone,
Thought I'd cracked my image problem by using the folllowing code I found in the microsoft resource.
Works fine in single form view however I have now created a new form that is displayed in the continuous form layout.
The image displayed for each individual form is the same as the rest dependant upon which form is highlighted at that time.
Any ideas how to get each forms own image displayed, prefferably using a similar code.
The images are linked to the database by a field in a table and the forms displayed are query results.
Any help would be fantastic, :)
Thanks for reading, Matt
Private Sub Form_AfterUpdate()
CallDisplayImage
End Sub
Private Sub Form_Current()
CallDisplayImage
End Sub
Private Sub txtImageName_AfterUpdate()
CallDisplayImage
End Sub
Private Sub CallDisplayImage()
Me!txtImageNote = DisplayImage(Me!ImageFrame, Me!txtImageName)
End Sub
stDocName = "Edit Form Search"
DoCmd.OpenForm stDocName, , , stLinkCriteria
View 1 Replies
View Related
Jan 4, 2014
I have a question about combo box , i want when i click on combo box show picture , for example i create a form by 2 languages (English,French) each language have a specific flag , when i click on the combo box show English and beside English show USA flag with French Language and beside French show flag of French.
View 3 Replies
View Related
Nov 4, 2013
I have a form with mulitple buttons that run different reports, I've used the mousemove VBA script to show text about the report when the cursor is placed over one of the buttons that all works fine.
Can get it to display a image when the cursor is placed over a button.
It'd just be a screenshot of the report output so the user gets an idea of the layout before they run it.
View 7 Replies
View Related
Nov 5, 2014
I have a text box [txtTrafficValue] that is a calculated field of two short times. I want an image to be visible if the value is >= 0.0104 (15 minutes). I have in the after update of the field:
if me.txtTrafficValue >= 0.0104 Then
Me.imgWarning.visible = true
Else
Me.imgWarning.visible = false
End if
but when the field does the calculation and updates the image is not appearing.
View 5 Replies
View Related
Apr 2, 2014
I have a form that I'd like to allow users to export to .xlsx via a button on the form. However I'd like to make it so that once the button is pressed, they are prompted to select a folder location before the export takes place.
I thought I would find a lot more 'how to' on this specific issue, but haven't had much luck.
View 5 Replies
View Related
Jan 26, 2014
I have two subforms on a main form. Both use similar queries and nearly the same set of records and PK. The first subform is for data entry and the 2nd subform is a continuous form that lists the entries in order that are made from the 1st Subform. (for entering in vacation days and appointments)
The continuous form cannot be edited, it is to be a list for viewing the information only.
I have an edit button next to each record on the continuous form. When the button is clicked, I want it to take the 1st subform to that specific record as well (same PK), so the information can be edited there.
I cannot figure out how to get the 1st subform to go to the record on the continuous form when the button next to that record is clicked on the continuous form.
I tried the DoCmdSearch for record and just keep getting object is not open errors.
View 2 Replies
View Related
Feb 26, 2015
in the attached form i can select multiple image but my next and back button does not work ,also i want the path to the file shown above.to copy the name from there and paste it in the table,to write remarks.
View 2 Replies
View Related
Jul 17, 2015
We're looking at a way that we can easily display what stage our clients' email marketing campaigns are at - in one section of our CRM our Campaign Manager will enter information on whether the campaign has broadcast (ie: emailed out to the required circulation list(s)), if we're waiting for artwork from the client or if we're chasing for that information.
I have four text boxes (date format) hidden on a subform that I need to pull ONE max date from.
So, as an example:
Email1 (our first email to the client chasing for artwork) = 01/01/2015
Email2 (our second email to the client chasing artwork) = 08/01/2015
Email3 (our third chase email) = 15/01/2015
Broadcast (the date the email campaign was finally sent) = 29/01/2015
I would need some code to show in an unbound textbox "Broadcast: 29/01/2015"
But, on the other hand, if the dates looked like this:
Email1 = 01/01/2015
Email2 = 08/01/2015
Email3 = Null
Broadcast = Null
I would need some code to show the following in an unbound textbox "Last Chased: 08/01/2015"
So we can easily see the status of our marketing campaigns at any stage in the process.
I've tried using IF THEN ELSE statements in the subform's On Current event, but that populates the information from the record you've selected across all the other records on the sub as well.
So I'm wondering if it's worth setting the Control Source of the unbound textbox I want to display the campaign status in as a bunch of nested IIF statements instead?
View 14 Replies
View Related
Aug 15, 2015
I have two tables, tblAdmin (which contains my attachment field, a logo) and tblRecords (which contains customer records.I created a form (frmMain) that displays customer records, and hooked frmMain to qrySelectCustomer, which is a query that... you guessed it!... selects a particular customer to view. I wanted the logo to appear at the top of this form, but it's in a separate table. I need to allow the database owner to go in and swap out one logo for another whenever he wants (if the business changes or whatever) and all my subsequent forms/reports have to pull this logo.
I can't use any kind of DLookUp for the image/attachment, because DLookUp only fetches text not images, so what I did was create a subform called frmLogo and hooked the subform to tblAdmin where the attachment resides. It works perfectly when I just open the frmLogo, the image displays as it should. But when I open frmMain, I get a parameter value prompt because it can't find the image! Even though the subform frmLogo that's on frmMain is hooked to the correct frmAdmin table!
I tried several things, but the only thing that solved the problem was to ALSO hook frmMain to tblAdmin, which I do NOT want to do, because then I have to create a THIRD form for the customer data and hook THAT to qrySelectCustomer!
View 3 Replies
View Related
Oct 14, 2013
One of the fields in my database stores a path of an image that I want to display on my form. I used the following code in the "On Current" event of my form to achieve this effect:
Private Sub Form_Current()
If IsNull(Me.text1) Then
Me.ImgPic.Picture = "C:UsersharrDesktopCupCake.jpg"
Else
Me.ImgPic.Picture = Me.text1
End If
End Sub
It works great with the exception that the image doesn't update when the path is changed. If I update the path, I have to navigate to the next record and then back again in order to see the new image. I've tried a couple of things to try to requery the image after the text control is updated, but so far none have worked. This is my most recent attempt on the after update event of my text box:
Code:
Private Sub text1_AfterUpdate()
Me!ImgPic.Requery
End Sub
How I can refresh the image after the text box control is updated?
View 9 Replies
View Related
Sep 14, 2014
I have a main form with a subform in continuous format. The subform displays the list of records and has a delete key allowing the user to delete that line (record) All works except if the user clicks the delete button on the new record line. Then there is an error message. Rather than use error trapping I would like to code a message OR simply beep to confirm nothing was done OR have the delete button disabled until something is entered into the record. The records do have a autonumber which I have in a hidden text box. I tried the following and even though the code shows that LineID does in fact = Null the code does not fire.
If Me.LineID = Null Then
DoCmd.Beep
Exit Sub
End If
View 4 Replies
View Related
Jan 4, 2015
I have a continuous subform on a form. I have applied conditional formatting with expression is.. so that the formatting on one object (field on the subform) depends on whether there is anything in another field on the same subform named "Remarks".
My problem is that I this is not working to my expectations. First of all when the form with the subform is loaded the conditional formatting does not appear immediately. One has to run over the fields with the mouse with the hope that the conditional formatting appears.
Secondly the conditional formatting is not working well as they should.
View 5 Replies
View Related
Jun 25, 2015
I am setting up a subform in continuous with combobox, but when I enter the data on the first combobox, it duplicated to all the following records. Is there a way to stop that?
View 2 Replies
View Related
Mar 3, 2015
i would like to have on my continuous subform fields from my table but only as a non-editable list (I have a dedicated mod form to actually modify the values), and I don't really like the way "Locked" and/or "Enabled" work, especially on combo boxes. To me, the arrow shouldn't be there: it looks like you can modify it, but you can't; it's a bit confusing and counter intuitive.
So what I did is replace those combo boxes with text boxes, and used DLookUp in the Control Source. Now I can lock and disable the text boxes and it looks just as I want it: you can't select the text, and most importantly there's no dropdown arrow.It works, but it's kind of a lot of work compared to what it is with the cbo. Also, since those are calculated values, they take a fraction of a second to appear, as opposed to the nearly instantaneous display of the values with the cbo, and there's only 5 entries in my test database.
View 8 Replies
View Related
Jul 1, 2013
I have an IIF function specified on a continuous sub-form as below - basically it checks to see if the value of two text boxes is equal, and if they are it displays 'And', if not it displays the value of the column EntitlementName. I'm trying to work around grouping not working in continuous forms.
When I view the form directly it works no problems but when I view the form as a sub-form instead of showing the correct output it shows #Name? Both the text boxes I refer to have the correct values in them.
=IIF([txtPrevValue]=[txtValue], Format("And"),Format([EntitlementName])
View 2 Replies
View Related
Jul 22, 2013
I have a continuous sub form linked to a master form. The sub form contains fields such as [date], [increase], [lastdateincrease], [task], and multiple other fields. The sub form can have one record or multiple records linked to the master form.
Each sub form record represents a service, monthly cost, and a price increase amount. I'd like to be able to enter data in two fields and have this data populate any remaining records, or for that matter, new records that I had to the sub form.
The fields that I would like to have populate are [date] and [increase].
When I enter the [date] and [increase] in the first record, I'd like all remaining records in the sub form to update with the [date] and [increase] amount automatically.
View 3 Replies
View Related
Jun 19, 2013
I have a calculated text box on a continuous form that doesn't paint in form view unless I click on the box.
View 2 Replies
View Related
May 1, 2014
I m having a subform in datasheet view. whn i use a join query as the record source for the sub form, i am not able to add or update any record in the datasheet. Is there anyway to use a linked query as record source of the datasheet with editable property.
View 2 Replies
View Related
Feb 10, 2015
I'm trying to use the following code to programmatically sort four fields on the continous subform:
Code:
Me.SPlanChange_03_OFFSET.Form.OrderBy = "AOBJ ASC, ORG ASC, AVAILABLE DESC, AGFND ASC"
Me.SPlanChange_03_OFFSET.Form.OrderByOn = True
It appears that the code works partially - the values in the "AOBJ" field are as they be and so are the values in "AVAILABLE" field. The values in the "ORG" and "AGFND" fields will not sort.
Is what I'm trying to do even possible?
View 1 Replies
View Related