Two issues re. using pre-configured pages.

 

I enabled debug mode using the browser console.  I then pressed Ctrl-F5 (cache reload) on an open process designer page, and tried to load the setup area of a pre-configured page element in the right hand panel.  It wouldn't load, the cursor just hung loading.  I then disabled debug mode and pressed Ctrl-F5 in the process designer window again.  The setup area of the pre-configured page element then loaded fine.

 

More problematic was the following while adding a button to run a process that opened a pre-configured page.  Using the debugger to step through a function that called the process with 'ProcessModuleUtilities', the configuration of the process call itself having a callback function for when the process had finished.  The debugger reported that the callback function was being called before the process had run and pre-configured page closed, not after.

define("ContactPageV2", ["ProcessModuleUtilities", "MaskHelper"], function(ProcessModuleUtilities, MaskHelper) {
	return {
		entitySchemaName: "Contact",
		attributes: {},
		modules: /**SCHEMA_MODULES*/{}/**SCHEMA_MODULES*/,
		details: /**SCHEMA_DETAILS*/{}/**SCHEMA_DETAILS*/,
		businessRules: /**SCHEMA_BUSINESS_RULES*/{}/**SCHEMA_BUSINESS_RULES*/,
		methods: {
			onProcessCallbackTestButtonClick: function () {
				debugger;
				const config = {
				    sysProcessName: "UsrPreconfiguredPage",
				    callback: function() {
				    	debugger;
				        Terrasoft.showInformation("The process has completed.");
				        MaskHelper.HideBodyMask();
				    },
				    scope: this
				};
				ProcessModuleUtilities.executeProcess(config);
			}
		},
		dataModels: /**SCHEMA_DATA_MODELS*/{}/**SCHEMA_DATA_MODELS*/,
		diff: /**SCHEMA_DIFF*/[
			{
				"operation": "insert",
				"name": "ProcessCallbackTestButton",
				"values": {
					"itemType": 5,
					"caption": "Process Callback Test",
					"style": "blue",
					"click": {
						"bindTo": "onProcessCallbackTestButtonClick"
					}
				},
				"parentName": "LeftContainer",
				"propertyName": "items",
				"index": 7
			},
			{
				"operation": "merge",
				"name": "JobTabContainer",
				"values": {
					"order": 2
				}
			},
			{
				"operation": "merge",
				"name": "HistoryTab",
				"values": {
					"order": 5
				}
			},
			{
				"operation": "merge",
				"name": "NotesAndFilesTab",
				"values": {
					"order": 6
				}
			},
			{
				"operation": "merge",
				"name": "ESNTab",
				"values": {
					"order": 7
				}
			}
		]/**SCHEMA_DIFF*/
	};
});

 

Like 0

Like

0 comments
Show all comments

Hello everybody

I'm working in file-system mode in a 7.18.5 development environment.

I need to override the OnSaving method of the Account entity then I created a custom EntityEventListener (following Creatio documentation).

I followed all the instructions of Creatio documentation  to setup my Visual Studio 2019 Enterprise and my local Creatio web application (see https://academy.creatio.com/docs/sites/en/files/pdf/guide/191/Debugging_7.18.pdf).

I worked both on "Compile into a separate assembly" package (in this case opening the package project file) and "traditional" package (in this case using the autogenerated Terrasoft.Configuration.sln solution).

When I attach to w3svc process my VS2019 (run as administrator) the breakpoints are not recognized because the symbols are not loaded. Then I force to load symbols so the breakpoints are recognized (see image below):

 

If I add a new break point during debug there's an error:

 

Anyway.. the debugging doesn't work: if I press F10 or F5 the breakpoints after the first are not manged and the execution ends.

 

So we have two main problems:

1) The symbols are not automatically loaded (but I can do it manually..)

2) The debugging tools dont work

 

I'm I doing something wrong?

I can I really debug server-side code?

Thanks

 

Like 0

Like

4 comments

Hello Massimiliano,

 

As for the automated symbols download - yes, please download them manually in case automated download didn't download all the symbols.

 

As for the breakpoint set - unfortunately there is no standard solution for this, only those described in forums here or here.

 

Best regards,

Oscar

Oscar Dylan,

Hello Oscar,

It seems related to the "Optimize code" option but it seems to me that Creatio compiles the packages in Release mode and not in Debug mode. Does the issue comes from that? Is there any solutions?

Thakns

Best regards

Massimiliano

Massimiliano,

 

<compilation debug="true" targetFramework="4.7">
        <assemblies>
          <add assembly="System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
        </assemblies>
      </compilation>

 

and all other settings performed in terms of the article you sent should compile packages in debug mode.

 

Best regards,

Oscar

Dear Oscar

I tried to change that setting in both web.config files (the "root one" and the "Terrasoft.WebApp one") but it didn't work. I saw that the dll's are compiled into the "Release" folder and not into "Debug" folder.

Am I doing something wrong?

If we set "debug=true" in the web.config files, are the packages created correctly to be deployed to production environments or do we need to reset the "debud=false" and recompile before exporting the packages?

Best regards

Massimiliano

Show all comments

Hi, 

 

Is there a a way to debug business processes in version 7.16.4.1473?

 

I found this but it doesn't work: 

https://academy.creatio.com/documents/technic-sdk/7-13/server-code-debu…

 

I found this too: https://academy.creatio.com/documents/technic-sdk/7-16/overview

But in this case, the business process does not generate a file .cs in the schema folder. 

 

Im using Clio to generate the packages projects, but the cs code of the bps its never generated in the packages. 

 

Looking forward to your comments. 

 

Best regards, 

 

Javier

Like 0

Like

3 comments

Dear Javier,

 

Thank you for your question!

The best way to monitor the Business Process error messages is to turn on the Traces parameter of a particular BP.

But please note that this may impact the system`s performance.

 

You may find these Academy Articles useful:

https://academy.creatio.com/docs/node/1790

https://academy.creatio.com/docs/node/1792

 

In addition, you may turn on the Debug mode of the whole Creatio itself by typing in this string in the browser`s console:

Terrasoft.SysSettings.postPersonalSysSettingsValue("IsDebug", true)

 

But please make sure to turn it off as you are finished as it impacts the system performance.

 

Hope this helps!
 

Regards,

 

Danyil

 

 

Hi Danyil, 

 

Thank you for your response, I know about Traces parameter, but actually I'm trying to debug server side business process' c# code(script task) in visual studio. 

 

Isn't that possible? 

 

Best regards, 

Javier

 

Javier Collazo,

 

Hi Javier,

 

This is only possible using C# interactive tools like dnSpy (can be downloaded from here) where you need to connect to w3wp.exe process of your application pool and debug the logic in real time.

 

As for connecting the app to Visual Studio - you can do it, but this feature was developed to allow development in the File system, but not debugging.

 

Best regards,

Oscar

Show all comments

I am trying to import the relationships via an excel file and have followed all the steps in making the file ready and matching the required data types etc.

The file is getting imported and I get a notification that my file has been imported but I can not see the relationships popping up under those accounts and contacts.

Could someone help me debug this or let me know if I am doing something wrong.

Thanks in advance

Regards,

Abhinav

Like 0

Like

2 comments

I get this notification: Import complete. 1 of 1 records imported from the source file "AK_Relationships.xlsx".

Hello

The Relationship table has following columns: http://prntscr.com/mkwsvu

In order to import relations you need to populate the RelationTypeId, ReverseRelationTypeId, Active, AccountAId(ContactAId) and AccountBId(ContactBId) columns. Please note, that you need to fill in the columns with the precise names in order for these relations to be connected to the existing records. Else, the duplicates might be created.

Best regards,

Matt

Show all comments