Hello...
I'd like to know how I can list the records in a subform through an autonumber field. I've tried to do it in the same way as in a main form, but it doesn't work for me. I'm really interested in learning how to use this powerful tool, but sometimes it's a bit complicated for me since I've been working with MS Access databases.
I would really appreciate if someone can help me on this particular issue.
Jose
Welcome to the nuBuilder Forums!
Register and log in to access exclusive forums and content available only to registered users.
Register and log in to access exclusive forums and content available only to registered users.
List the records in a subform through an autonumber field
-
- Posts: 27
- Joined: Thu Sep 01, 2022 3:42 am
- Has thanked: 1 time
-
- nuBuilder Team
- Posts: 4292
- Joined: Sun Oct 14, 2018 6:43 pm
- Has thanked: 71 times
- Been thanked: 444 times
- Contact:
Re: List the records in a subform through an autonumber field
Hi Jose
I'm afraid AUTO_INCREMENT is not supported in subforms (unless it's readonly)
I'm afraid AUTO_INCREMENT is not supported in subforms (unless it's readonly)
-
- Posts: 27
- Joined: Thu Sep 01, 2022 3:42 am
- Has thanked: 1 time
Re: List the records in a subform through an autonumber field
Hello Kevin
I am very grateful for your answer, I had been trying to do an AUTO_INCREMENT in this type of object for some time, but now I have it clear.
I want to ask you another question... How can I make data from a main form copy to a specific field of a subform?
...and thank you very much for your willingness to help me!!!
I am very grateful for your answer, I had been trying to do an AUTO_INCREMENT in this type of object for some time, but now I have it clear.
I want to ask you another question... How can I make data from a main form copy to a specific field of a subform?
...and thank you very much for your willingness to help me!!!
-
- nuBuilder Team
- Posts: 4292
- Joined: Sun Oct 14, 2018 6:43 pm
- Has thanked: 71 times
- Been thanked: 444 times
- Contact:
Re: List the records in a subform through an autonumber field
Example:
PS:
It is generally not recommended to ask multiple questions in one topic because it can make it difficult for other users to understand what you are asking and to provide specific and relevant answers. Additionally, it can also make it difficult for others to follow the conversation and contribute to the discussion. It's best to create separate threads for each question, with a clear and specific title. This will help others understand what you are asking and provide better answers.
Code: Select all
// Set a cell value. If row not specified -> last row
// id: subform object id
// column: object id
// value to set
// row number
function subformSetValue(id, column, value, row) {
if (row === undefined) {
var r = nuSubformObject(id).rows.length - 1;
} else {
var r = row;
}
$('#' + id + nuPad3(r) + column).val(value).change();
}
// Example:
subformSetValue('your_subform_id', 'subform_column_id', object_id_on_main_form.value, 1);
It is generally not recommended to ask multiple questions in one topic because it can make it difficult for other users to understand what you are asking and to provide specific and relevant answers. Additionally, it can also make it difficult for others to follow the conversation and contribute to the discussion. It's best to create separate threads for each question, with a clear and specific title. This will help others understand what you are asking and provide better answers.
-
- Posts: 27
- Joined: Thu Sep 01, 2022 3:42 am
- Has thanked: 1 time
Re: List the records in a subform through an autonumber field
Ok, I got it... anyway, thank you very much for the clarification and for the code. I'm going to run it in my application to see if it works for me and I'll let you know.
Regards...
Regards...