So I want to add a component to the bottom of a panel. Normally you would just do the following:
Ext.getCmp('xxxx').add({....});
and that will add to the bottom, but for some reason when you add itemId it all goes to hell. Here is a working example: http://jsfiddle.net/Qsfgh/ Notice how the 'higher' id comes before the lower one. (You can open your console and look at the HTML if you want to verify) Even when I use an 'insert' and I insert it at the very end it still puts it at the beginning. How do I get around that?
Both the fields you're adding have the same itemId. ItemIds don't have to be globally unique, but they do have to be unique for components within the same container. The itemId is used as the key for a component in the owning container's mixed collection of items (if no itemId is set on the component, the id is used instead).
So when you are adding the second field, it replaces the first field in the container's collection of items and screws up the rendering process. Give the fields different itemIds and everything will work properly.
If you give each field a unique itemId you no longer need to absolutely position the fields. Field 2 will be placed correctly beneath Field 1
Related
I am trying to create a form, in which the person fills in a title and other info in the first page, and I would like to have this info update in the whole document's headers, so each section wouldn't have to be manually updated.
I created legacy text form fields and a drop-down list, so I could bind them to bookmarks, which I wanted to reference.
When I put the references in the body of the next sections, they do update once I tab out of the fields, but the header remains empty with the same references.
Any tips on how to approach the problem?
I did try with creating unique styles for these items and referencing that, but it was also unsuccessful.
I also aim to have other parts of the form updating based on the drop-down list selection by using field codes. The first attempt is also working in the body of the document, so it's mainly the headers I am struggling with.
I have Drupal 7.58 site where there's a select list with 15 items that come from an entity reference. When I put a debugging statement into form_type_select_value in includes/form.inc, the whole array of items is there, so I know the query is working, and the form element should be built correctly.
But when the select list is display, the sixth element goes missing. I've found a short term way to circumvent this, by adding a dummy sixth item, but that's not going to fly in the long term.
What I need to know is where does it go after form_type_select_value?
edit: More info
This is happening in an Entityform where the field type is Entity Reference and the Widget is Select List. In Manage Fields under Entity Selection, I select an entity called Store, in Simple mode. There are 15 Stores, and these are sorted by the Title property, sorted in the Ascending direction.
When I sort in Descending direction, a different item is missing, but it's always the 6th from the top.
I've debugged it up to the point where the data comes in, before it's rendered, and it's all there in the outgoing array.
I am creating an org chart from an excel spreadsheet. Each row has Employee Name and Job Title, but also Employee ID and Supervisor Employee ID (both number data types).
I am using the Organization Chart Wizard to automatically create an org chart as a starting point (its pretty big). In doing so, I use the two numeric fields in the "name" and "reports to" fields because we have employees with the same name. However, I do not want these numerical fields displayed in the org chart shapes. You can see in the second picture I cannot remove the three default fields from the chosen "Shape Data Fields."
Here's what the shapes look like, I want to remove the number field altogether. Regardless of the shape stencil I select, I get the same behavior.
If I try to delete the shape, I get the error "shape protection, container and/or layer properties prevent complete execution." Even when I go to Developer -> Protection -> Unlock, the issue persists. Thus, it must be an issue with the container or layer properties.
Lastly, this page has a "To Delete a data field" section at the bottom. I tried exactly this, and the fields were removed from the Define Shape Data box, but the shapes remained unchanged, still showing all fields:
https://support.office.com/en-us/article/Add-data-to-shapes-09272394-5243-4e1b-bcfa-425a8b4d1ce2?ui=en-US&rs=en-US&ad=US
Tweak the master you want to use by decorticating its structure.
In the drawing explorer check whether the shape (the master) is group or a single shape. Find out where the ID (the 3rd field) is used for display, adjust accordingly by correcting the shapesheet.
Sorry for such a generic explanation. If we could exchange files, I would have had a look at your master and could have corrected it.
HTH, Y.
I had the same issue, and eventually found that I could prevent the ID field (used in Name) from displaying, using Display Options - on the Org Chart tab, using the dialog box launcher button (bottom-right) in the Shapes section.
The ID field is shown as 'Name' under Block 2 - you can use the drop-down to set this to 'None' (so that it doesn't display at all), or pick one of the other fields that you chose to display in its place.
I have a main form called fm_Main. This fm_Main contains an embedded view which has 2 actions: Add & Delete. When I click Add is opening another form called fm_Second and here I can add some fields which will be displayed on the embedded_view on fm_Main.
The problem is: Let say I have 3 documents. All of them contains an empty embedded view. If I add some value fields in one document into the embedded view and then I save that document, all the 3 documents contains that values into the embedded. It should be: just one of them should cotain because I modified only one, the 2 of them shoudn't have that values displayed in the embedded view. Thank you!
PS: Also if I saved one document with an entry into the embedded view. When I want to create another new document, in the embedded view there exists the last entry from the last document. I want to be empty!
You must filter the embedded view to only show the entries related to the currently open main document.
Most programmers would use the UniversalID of the main document, it can be automatically populated into the entries you create.
One thing to think about is that you may want to store the Universal ID in a computed when composed field on teh main document. If you get a replication error in the future, the Universal ID may change, and you will not be able to get to the entries in the embedded view.
I been doing exactly this in several large Notes databases, works perfectly fine.
Expanding on Karl-Henry's suggestion, you should make into a categorized view and use the Show Single Category feature of the embedded view. I might suggest using the #Unique function instead of the UNID to relate the Main and Second documents, but that's a matter of preference. In either case, you have to make sure that the value inherits down into a field in the Second docs, and you can use that field as the category for the view.
On a form, I have a combobox, with the RowSource coming from a query (specifically, a calculated field in the query). When the user makes a selection, I want to update a label on the same form with a different column from that same query, but of course associated to the selection.
I'm fine with VBA and writing queries and whatnot, but I am not very familiar with Access forms.
By the way, I tried searching for an answer to this, but it was quite difficult because I don't know what this thing is really called that I am trying to do. A good link to a site explaining this would be perfectly fine (no need to write a bunch of stuff here if it already exists elsewhere).
In the After Update event of my combo box, cboUserID, I can set a label control, lblFoo, to the value of the second column in the selected row of the combo.
Me.lblFoo.Caption = Me.cboUserID.Column(1)
If your combo box is bound to a field in the form's record source, you may want to do that same operation from the form's On Current event also.
You can use the column property to refer to anything other than the bound column of a combo.
Rowsource: SELECT ID, SName, FName FROM Table
Me.MyCombo.Column(2)
This would return FName.
-- http://msdn.microsoft.com/en-us/library/aa224084(v=office.11).aspx
Me.MyLabel.Caption = Me.MyCombo.Column(2)