Using EXCEL 2016 'LEN' and 'CELL' functions, nested together
I need to combine two EXCEL 2016 worksheet functions, to later parse resultant text string. According to online Help Page...
(a) CELL("filename", $A$1) - "Filename (including full path) of the file that contains reference, as text. Returns empty text ("") if the worksheet that contains reference has not yet been saved. Note: This value is not supported in Excel Online, Excel Mobile, and Excel Starter."
(b) LEN($A$1) - "LEN returns the number of characters in a text string."
Combining the two functions, with $A$1 contents having been saved previously:
LEN(CELL("filename", $A$1))
The resulting number is not the same as the number of characters visually inspected in the address/file string. LEN(CELL) is one more than inspected.
I tried using TRIM, to ensure non-printable characters were suppressed. But, the results are the same:
LEN(CELL("filename", $A$1)) = LEN(TRIM(CELL("filename", $A$1)))
Have I failed to see Help Page documentation, which would account for the difference? Or, is the CELL result not actually a Text string, as defined?
microsoft-excel-2016
add a comment |
I need to combine two EXCEL 2016 worksheet functions, to later parse resultant text string. According to online Help Page...
(a) CELL("filename", $A$1) - "Filename (including full path) of the file that contains reference, as text. Returns empty text ("") if the worksheet that contains reference has not yet been saved. Note: This value is not supported in Excel Online, Excel Mobile, and Excel Starter."
(b) LEN($A$1) - "LEN returns the number of characters in a text string."
Combining the two functions, with $A$1 contents having been saved previously:
LEN(CELL("filename", $A$1))
The resulting number is not the same as the number of characters visually inspected in the address/file string. LEN(CELL) is one more than inspected.
I tried using TRIM, to ensure non-printable characters were suppressed. But, the results are the same:
LEN(CELL("filename", $A$1)) = LEN(TRIM(CELL("filename", $A$1)))
Have I failed to see Help Page documentation, which would account for the difference? Or, is the CELL result not actually a Text string, as defined?
microsoft-excel-2016
Could you provide a sample picture?
– Lee
Jan 16 at 1:03
if it is always one more than inspected.. then adding a "-1" after len() will do it.
– p._phidot_
Jan 17 at 1:54
add a comment |
I need to combine two EXCEL 2016 worksheet functions, to later parse resultant text string. According to online Help Page...
(a) CELL("filename", $A$1) - "Filename (including full path) of the file that contains reference, as text. Returns empty text ("") if the worksheet that contains reference has not yet been saved. Note: This value is not supported in Excel Online, Excel Mobile, and Excel Starter."
(b) LEN($A$1) - "LEN returns the number of characters in a text string."
Combining the two functions, with $A$1 contents having been saved previously:
LEN(CELL("filename", $A$1))
The resulting number is not the same as the number of characters visually inspected in the address/file string. LEN(CELL) is one more than inspected.
I tried using TRIM, to ensure non-printable characters were suppressed. But, the results are the same:
LEN(CELL("filename", $A$1)) = LEN(TRIM(CELL("filename", $A$1)))
Have I failed to see Help Page documentation, which would account for the difference? Or, is the CELL result not actually a Text string, as defined?
microsoft-excel-2016
I need to combine two EXCEL 2016 worksheet functions, to later parse resultant text string. According to online Help Page...
(a) CELL("filename", $A$1) - "Filename (including full path) of the file that contains reference, as text. Returns empty text ("") if the worksheet that contains reference has not yet been saved. Note: This value is not supported in Excel Online, Excel Mobile, and Excel Starter."
(b) LEN($A$1) - "LEN returns the number of characters in a text string."
Combining the two functions, with $A$1 contents having been saved previously:
LEN(CELL("filename", $A$1))
The resulting number is not the same as the number of characters visually inspected in the address/file string. LEN(CELL) is one more than inspected.
I tried using TRIM, to ensure non-printable characters were suppressed. But, the results are the same:
LEN(CELL("filename", $A$1)) = LEN(TRIM(CELL("filename", $A$1)))
Have I failed to see Help Page documentation, which would account for the difference? Or, is the CELL result not actually a Text string, as defined?
microsoft-excel-2016
microsoft-excel-2016
asked Jan 15 at 16:04
Tom MTom M
1
1
Could you provide a sample picture?
– Lee
Jan 16 at 1:03
if it is always one more than inspected.. then adding a "-1" after len() will do it.
– p._phidot_
Jan 17 at 1:54
add a comment |
Could you provide a sample picture?
– Lee
Jan 16 at 1:03
if it is always one more than inspected.. then adding a "-1" after len() will do it.
– p._phidot_
Jan 17 at 1:54
Could you provide a sample picture?
– Lee
Jan 16 at 1:03
Could you provide a sample picture?
– Lee
Jan 16 at 1:03
if it is always one more than inspected.. then adding a "-1" after len() will do it.
– p._phidot_
Jan 17 at 1:54
if it is always one more than inspected.. then adding a "-1" after len() will do it.
– p._phidot_
Jan 17 at 1:54
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1394587%2fusing-excel-2016-len-and-cell-functions-nested-together%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1394587%2fusing-excel-2016-len-and-cell-functions-nested-together%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Could you provide a sample picture?
– Lee
Jan 16 at 1:03
if it is always one more than inspected.. then adding a "-1" after len() will do it.
– p._phidot_
Jan 17 at 1:54