Home › Forums › Classic DFFS › spjs.dffs.data.lcidToDateFormat
- This topic has 20 replies, 4 voices, and was last updated 8 years, 4 months ago by Alexander Bautz.
-
AuthorPosts
-
-
March 30, 2015 at 11:27 #7334
Hello Alexander,
I have this message:
The date format for LCID undefined is not configured.
Either make a request for an update here: https://sharepointjavascript.wordpress.com/
Or add the correct format in the variable
“spjs.dffs.data.lcidToDateFormat”.How to do it? I use Czech language – lcid=1029 (dd.mm.yyyy)
Thanks
Michal -
April 1, 2015 at 13:15 #7341
Solved – caused by wrong rule.
Adding a new entry to lcidToDateFormat for LCID 1029 with no result, but corect wrong rule solved this issue.
Michal -
April 6, 2015 at 13:03 #7354
I’m glad you figured it out.
Alexander
-
May 11, 2015 at 06:54 #7613
Hi
I get the same error when I try to compare a date field in my form (Trigger: field changed) to [today]. I wan’t to set a rule [if date field is less than [today]]. Is there a way to get around?
Thanks
Corina -
May 12, 2015 at 21:05 #7630
Hi Corina,
What LCID (language) are you using in your SharePoint site?Alexander
-
May 15, 2015 at 19:17 #7642
English, where canIi find the exact value?
-
May 18, 2015 at 16:27 #7645
Hi,
You can find it by looking at the page source – depending on which version of SharePoint you use, the variable is either “L_Menu_LCID” or “currentLanguage” as property of the “_spPageContextInfo” object.Could you have other errors in some custom code that causes this? – look at the developer console (hit F12 > Console).
Alexander
-
May 21, 2015 at 10:11 #7676
I get this message in the console and the one which is attached is popping up:
Uncaught TypeError: Cannot read property ‘separator’ of undefined
spjs.dffs.strToDateObj @ VM3509:1
(anonymous function) @ VM3509:1
m.extend.each @ jquery-1.11.1.min.js:2
spjs.dffs.applyRules @ VM3509:1
(anonymous function) @ VM3509:1Language field is:
var L_Menu_LCID=”1033″;- This reply was modified 9 years, 6 months ago by Corina Honegger.
Attachments:
-
May 26, 2015 at 07:16 #7691
Hi,
Sorry for the delay, the problem is that the variable is undefined. Can you post here (or email to me) screenshots of the rule that causes this error?Also, specify the version number for DFFS frontend and backend, and the SharePoint version.
Alexander
-
July 14, 2016 at 12:20 #12365
Hi Alexander,
I have run into this same issue as Corina and Riha. I can’t remember how, but after I got the initial error I checked around in the developer console and it said there was a splitter issue that appeared to be in reference to it splitting the date and time into separate fields. My LCID is 1033, but like Riha Michal, deininf it in the code hasn’t changed anything. I don’t know if I have a “wrong rule” like him, but I would very much like to get this solution to work. Thank you so much for any assistance you can offer.
-
July 18, 2016 at 08:32 #12399
Hi,
Are you using any custom code to set a date and time column, or do you use the “set field value” in a rule to do the same?Alexander
-
July 18, 2016 at 15:03 #12403
There shouldn’t be anything custom. After I got this error on our main list, I created a brand new list to use as a control. I added a column to be the resource, and then I added a start date “date and time” column and an end date “date and time” column. After that I added the solution to the default form. I didn’t do anything else and I got the same error as on the main list. If there is anything I can provide to help figure this out please let me know. I’d really like to find a way to get this to work. Thank you.
- This reply was modified 8 years, 4 months ago by Brent Miller.
-
July 20, 2016 at 07:40 #12430
Is the error originating from the resource-management solution? – I use the function “lcidToDateFormat” in both.
Can you attach a few screenshots of the form and your setup so I can try to understand where the error originates from?
Alexander
-
July 20, 2016 at 17:07 #12445
I’ve attached pictures of most everything I could think of as well as the full code for the form in question.
-
July 21, 2016 at 08:56 #12453
Hi,
The reason for the error message is that the query to find the correct LCID (language) of the list you are targeting fails to return the LCID.The “spjsRmArgs” object is set up for SharePoint 2007, and I guess this is why it fails. Try removing the “listName” from this object.
var spjsRmArgs = { "resourceField":"resource", "dateFrom":"StartDate", "dateTo":"EndDate", "timeFormat":24, "bookableTimeRangeActive":false }; spjs.rm.init(spjsRmArgs);
Alexander
-
July 21, 2016 at 13:59 #12456
I get the same error as before, but a new error preceding it. It actually tells me to add in the list name which is why I had it in there before. I’ve attached an image of the error. Once I click past this new error, I get the same LCID error as before immediately afterwards. I can’t imagine there is any setting in our sharepoint site that could be causing this as I’ve tried it in our onsite 2013 version and then I’ve tried it in the cloud where we just migrated to. Any other ideas? Thank you for your help.
Attachments:
-
July 22, 2016 at 15:39 #12467
Can you open the developer console (hit F12 > Console) and type in this and press enter:
_spPageContextInfo
How does the output look?
How are you referring the scripts? – in a CEWP in the page? – the reason I ask is that the check to see if you are using SP 2007 or newer is done by checking the variable _spPageContextInfo to see which version it returns. This variable does not exist in SP 2007, but is loaded with the master page in SP 2013. If you have added the script file in the master page, and it loads before the default SharePoint files you will get this error.
Alexander
-
July 22, 2016 at 15:54 #12471
I’m not entirely sure what you mean by referring the scripts, but there aren’t any CEWPs in the current page. I am a programmer, but I’m still pretty new to sharepoint and web coding in general. I checked all the master pages I know of and didn’t see anything that looked like a CEWP. That said though, we HAD sharepoint 2007, migrated to 2010 and recently to 2013(now to the cloud). So I’d be shocked if there wasn’t some left over code in the page somewhere, but I’m not really sure how to find it if that’s the case.
Here is the output and I attached an image of the console as it mentions SCRIPT5 having Access denied. Wasn’t sure if it was relevant.
[object Object]{alertsEnabled: true, allowSilverlightPrompt: “True”, clientServerTimeDelta: -3704, crossDomainPhotosEnabled: true, currentCultureName: “en-US”, currentLanguage: 1033, currentUICultureName: “en-US”, env: “Prod”, hasManageWebPermissions: true, isAnonymousGuestUser: false, isAppWeb: false, isSiteAdmin: true, layoutsUrl: “_layouts/15”, pageListId: “{558f7f7d-5…”, pagePersonalizationScope: 1, ProfileUrl: “https://ass…”, serverRequestPath: “/Lists/Test…”, siteAbsoluteUrl: “https://ass…”, siteClientTag: “355$$16.0.5…”, siteServerRelativeUrl: “/”, systemUserKey: “i:0h.f|memb…”, tenantAppVersion: “0” …}
Thank you again for all of your help.
Attachments:
-
July 22, 2016 at 22:47 #12486
The output looks right. What I meant by “referring the scripts” was how you have set up the resource management solution. Are you using it with DFFS or as a standalone solution – from the screenshot it looks like you don’t use DFFS?
If you use it standalone, I guess you have put a CEWP or script editor web part in the page to load the script?
Alexander
-
July 26, 2016 at 20:05 #12521
Sorry it took me so long to reply, I got super busy and wanted to test thoroughly before replying. To answer your question I wasn’t using either of those. I had been advised to put the code into an </asp:Content> tag instead. After putting it into a CEWP it actually still didn’t work, but this was actually because the excess code I had added to make it work before was breaking it. Once I removed that it seems to be working perfectly now. Thank you so much for all of your time and patience. You are a life saver.
-
July 27, 2016 at 08:12 #12532
I’m glad you figured it out.
Alexander
-
-
AuthorPosts
- You must be logged in to reply to this topic.