VBA Why is my number content transfer back to dateOutlook vba count folder items between datesFor Each loop not going through all the dataVBA erases local currency number formatCreating Unique ID Based on Date, and Number of RequestsVBA Userform Date/Time Stamp - UK Date changes to US format when copied to cellFormatting chart data labels with VBAExcel VBA PasteSpecial not pasting consistentlyCreate an ID number based off form fields - AccessDate formats in VBA from Text StringCreating a lot number using Julian/Ordinal date from a yyyy-mm-dd and concatenate in VBA
What's the purpose of "true" in bash "if sudo true; then"
Why is Lord Kartikeya called 'Devasenapati'?
Balance Issues for a Custom Sorcerer Variant
You cannot touch me, but I can touch you, who am I?
Unexpected indention in bibliography items (beamer)
Does "every" first-order theory have a finitely axiomatizable conservative extension?
Class Action - which options I have?
Term for the "extreme-extension" version of a straw man fallacy?
Implement the Thanos sorting algorithm
Is this apparent Class Action settlement a spam message?
Closest Prime Number
What does this 7 mean above the f flat
How to check is there any negative term in a large list?
Was Spock the First Vulcan in Starfleet?
How do I find the solutions of the following equation?
How can we prove that any integral in the set of non-elementary integrals cannot be expressed in the form of elementary functions?
How does it work when somebody invests in my business?
Large drywall patch supports
What to do with wrong results in talks?
Italian words for tools
How to safely derail a train during transit?
Opposite of a diet
Nautlius: add mouse right-click action to compute MD5 sum
How to pronounce the slash sign
VBA Why is my number content transfer back to date
Outlook vba count folder items between datesFor Each loop not going through all the dataVBA erases local currency number formatCreating Unique ID Based on Date, and Number of RequestsVBA Userform Date/Time Stamp - UK Date changes to US format when copied to cellFormatting chart data labels with VBAExcel VBA PasteSpecial not pasting consistentlyCreate an ID number based off form fields - AccessDate formats in VBA from Text StringCreating a lot number using Julian/Ordinal date from a yyyy-mm-dd and concatenate in VBA
I intend to input a series of number into the spreadsheet which is the last number of year of my date & the Julian date & the number of my date if I set 2/6/2019 as 1001.
Here is my Code:
AddNew.Offset(m, 4).Value = Right(Year(DTPickerActualHarvestDate), 1) & _
Format(DatePart("y", DTPickerActualHarvestDate), "000") & _
DateValue(DTPickerActualHarvestDate.Value) - 42501
The problem is if I input DateValue(DTPickerActualHarvestDate.Value) - 42501by itself, it will come up with the right result and so does the former part. But when I put them together, the last part would transfer from number back to date again. For example, if my date is 2/6/2019, it should show up with 90371001 while it now shows as 90379/27/1902.How can I fix this?
vba
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
I intend to input a series of number into the spreadsheet which is the last number of year of my date & the Julian date & the number of my date if I set 2/6/2019 as 1001.
Here is my Code:
AddNew.Offset(m, 4).Value = Right(Year(DTPickerActualHarvestDate), 1) & _
Format(DatePart("y", DTPickerActualHarvestDate), "000") & _
DateValue(DTPickerActualHarvestDate.Value) - 42501
The problem is if I input DateValue(DTPickerActualHarvestDate.Value) - 42501by itself, it will come up with the right result and so does the former part. But when I put them together, the last part would transfer from number back to date again. For example, if my date is 2/6/2019, it should show up with 90371001 while it now shows as 90379/27/1902.How can I fix this?
vba
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
I intend to input a series of number into the spreadsheet which is the last number of year of my date & the Julian date & the number of my date if I set 2/6/2019 as 1001.
Here is my Code:
AddNew.Offset(m, 4).Value = Right(Year(DTPickerActualHarvestDate), 1) & _
Format(DatePart("y", DTPickerActualHarvestDate), "000") & _
DateValue(DTPickerActualHarvestDate.Value) - 42501
The problem is if I input DateValue(DTPickerActualHarvestDate.Value) - 42501by itself, it will come up with the right result and so does the former part. But when I put them together, the last part would transfer from number back to date again. For example, if my date is 2/6/2019, it should show up with 90371001 while it now shows as 90379/27/1902.How can I fix this?
vba
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I intend to input a series of number into the spreadsheet which is the last number of year of my date & the Julian date & the number of my date if I set 2/6/2019 as 1001.
Here is my Code:
AddNew.Offset(m, 4).Value = Right(Year(DTPickerActualHarvestDate), 1) & _
Format(DatePart("y", DTPickerActualHarvestDate), "000") & _
DateValue(DTPickerActualHarvestDate.Value) - 42501
The problem is if I input DateValue(DTPickerActualHarvestDate.Value) - 42501by itself, it will come up with the right result and so does the former part. But when I put them together, the last part would transfer from number back to date again. For example, if my date is 2/6/2019, it should show up with 90371001 while it now shows as 90379/27/1902.How can I fix this?
vba
vba
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked Mar 21 at 15:50
Poppy YuanPoppy Yuan
11
11
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Poppy Yuan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
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
);
);
Poppy Yuan is a new contributor. Be nice, and check out our Code of Conduct.
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%2fstackoverflow.com%2fquestions%2f55284348%2fvba-why-is-my-number-content-transfer-back-to-date%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
Poppy Yuan is a new contributor. Be nice, and check out our Code of Conduct.
Poppy Yuan is a new contributor. Be nice, and check out our Code of Conduct.
Poppy Yuan is a new contributor. Be nice, and check out our Code of Conduct.
Poppy Yuan is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to Stack Overflow!
- 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%2fstackoverflow.com%2fquestions%2f55284348%2fvba-why-is-my-number-content-transfer-back-to-date%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