- Home
- Forum
- ASP.NET MVC - EJ 2
- Add Picture once and re-use it at multiple locations
Add Picture once and re-use it at multiple locations
Attachment: Data_c03ecf88.zip
|
Queries |
Details | |
|
The worksheets is created dynamically and Each time Image logo is added and data is appended.
As it running for 800+ records , execution is timing out. (It's going upto 4 Minutes)
Without image embedding, it finishes in 30-60 seconds for the same data and number of records.
Can we add image only once using AddPicture method and use it or copy it at multiple locations using Indices. (Exact location where to copy will be available) ?
This is to improve performance. Or is there any other way add logo images so that performance is not affected drastically.
PFA of code file required.
Attachment: Data_c03ecf88.zip |
We are not facing performance issue while adding pictures multiple times. We have prepared sample for adding pictures as per your scenario and it gets added in few seconds. Please find the sample for the same from following link.
So, please get back to us with below details to validate further from our side.
| |
|
How to display custom text in grid column based on Column value ?
eg. IsTestRun is boolean column.
If it is true display Yes , and No if false.
How do we specify column type is boolean and add custom text for it ?
col.Field(p => p.IsTestRun).HeaderText("IsTestRun").Type("bool").TextAlign(TextAlign.Left).Add();
|
We can achieve your requirement using the ValueAccessor property of Grid.
Here we have modify the “Verified” column value into Yes/No based on those column value.
| |
|
How to format date display ?
Eg. Startzeit is of string datatype and has date value.
How to format it look like as below ?
How to handle check for null values? If Null display NA
col.Field(p => p.Startzeit).HeaderText("Startzeit").Format("{0:dd/MM/yyyy }").TextAlign(TextAlign.Left).Add();
|
We can achieve your requirement using the Format property of Grid.
Here, we have set the customized format for “OrderDate” column in Grid.
Refer the help documentation.
We have prepared a sample with the solution of both the queries and it can be downloadable from the below location.
|
1. Performance issue:
- Picture used at your end. :
PFA
- Syncfusion working
version: Syncfusion.EJ.MVC, Version=16.3500.0.29
- Modified issue reproducing
sample. PFA.
2. Formatting Queries: Both of the answers for the below queries do not
seem to be working. (Used version EJ and not EJS).
Attachment: QueryData_721ceef4.zip
|
Queries |
Details | |
|
Performance issue:
|
We are unable to reproduce the issue with the shared details. Shared image is added 800 times in the worksheet within 10 seconds. We request you to share the issue reproducing runnable sample which will be helpful for us to analyse performance issue from our side. | |
|
Formatting Queries: Both of the answers for the below queries do not seem to be working. (Used version EJ and not EJS).
- Had already tried Format property which seems to be not working.
-ValueAccessor looks like not available in EJ. |
We can display the custom text using the QueryCellInfo event of ejGrid and by defining the format with type in column definition we can show value with desire format. Refer the below code example,
Output:
|
Attachment: PerfIssue_864bc3c9.zip
Please find the details below.
Queries | Details |
1. QueryCellInfo - This seems to be working.
| We are glad that the issue is resolved at your end. |
2. Date Formatting - Still, it seems to be not working.
| We need some more additional details to find the cause of the issue. Share us the following details.
1. Complete Grid code example. 2. How do you have bind dataSource for the string datatype date value(Date column). Share your example value. 3. Share Screenshot of the issue. 4. Share us the simple Demo with duplicate values to replicate your issue. |
3. Performance Issue - PFA of running code snippet.
| We are able to reproduce the issue with the shared sample and validating it currently. We will update further details by 4thSeptember 2019. |
Regards,
Abirami
This patch should replace Syncfusion.XlsIO.Base.dll under the following folder.
Eg : $system drive:\Program Files\Syncfusion\Essential Studio\17.2.0.46\precompiledassemblies\17.2.0.46\4.6
To automatically run the Assembly Manager, please check the Run assembly manager checkbox option while installing the patch. If this option is unchecked, the patch will replace the assemblies in precompiled assemblies’ folder only. Then, you will have to manually copy and paste them to the preferred location or you will have to run the Syncfusion Assembly Manager application (available from the Syncfusion Dashboard, installed as a shortcut in the Application menu) to re-install assemblies.
Note:
Disclaimer :
Please note that we have created this patch for version 17.2.0.46 specifically to resolve the issues reported in this forum.
If you have received other patches for the same version for other products, please apply all patches in the order received.
This fix will be included in our latest release 17.3 SP – 1 which will be rolled out by October 2019.
- 16 Replies
- 3 Participants
-
VM Vaibhav More
- Aug 20, 2019 10:37 AM UTC
- Jan 6, 2020 05:27 AM UTC