Stimul Report : businessObjects doesn't load by showing the report - stimulsoft

I save the report template :
report.Save("C:\\kk.mrt");
then I load the saved report and assign it BusinessObjects as Dictionaries
StiReport rptLoad = new StiReport();
rptLoad.RegBusinessObject("Company", repository.GetAll<Company>());
rptLoad.Load("C:\\kk.mrt");
rptLoad.BusinessObjectsStore contains registered BusinessObjects just registered (Watched at RunTime) but :
rptLoad.Show();
IF there are Bindings (Like: Components.Add(new StiText{Text="{Company.Name}"}) included in the saved report : THEN
gets me : error CS0103: The name 'Company' does not exist in the current context
ELSE IF I have no Bindings in saved report : THEN
rptLoad.Show(); will show the report , but with no registered Dictionaries (As i go to design mode after showing the report I see no BusinessObjects in Dictionary).
And IF I call rptLoad.Design(); before rptLoad.Show(); : THEN
the report shows and Bindings are OK and I can see BusinessObjects in the shown report (in both design and preview mode).

Found the cause :
rptLoad.Dictionary.Synchronize();
should call after rptLoad.RegBusinessObject("Company", repository.GetAll<Company>());

Related

Is there a way to resolve this error: "CloudKit integration requires does not support ordered relationships."

I'm trying to use Apple's CoreDataCloudkitDemo app. I've only changed the app settings per their README document. On running the demo, I'm getting the error: "CloudKit integration requires does not support ordered relationships."
(The weird grammar in the title is included in the app)
The console log shows:
Fatal error: ###persistentContainer: Failed to load persistent stores:Error Domain=NSCocoaErrorDomain Code=134060 "A Core Data error occurred." UserInfo={NSLocalizedFailureReason=CloudKit integration requires does not support ordered relationships. The following relationships are marked ordered:
Post: attachments
There is the same error for the "Tags" entity.
I'm using Xcode 11.0 beta 4 (11M374r).
I've only changed the bundle identifier, and set my Team Id.
I removed the original entitlements file - no errors in resulting build.
I've not changed any code from the original.
Does anyone have a workaround, or preferably, a fix? Or did I do something wrong?
Thanks
Firstly, select CoreDataCloudKitDemo.xcdatamodeld -> Post -> RelationShips, select attachments relationship, on the Inspect panel, deselect Ordered, then do the same thing on the tags relationship.
Secondly, there will be some errors in the code now, because we unchecked the Ordered option, the property of attachments and tags in the generated NSManagedObject may changed from NSOrderedSet? to NSSet?. So we could change these error lines of code like below:
Origin:
guard let tag = post?.tags?.object(at: indexPath.row) as? Tag else { return cell }
Changed:
guard let tag = post?.tags?.allObjects[indexPath.row] as? Tag else { return cell }
Finally, you can run the code now. ;-)
Further more, on WWDC19 Session 202, the demo shows they set both attachments and tags relationships as Unordered, so I think there's something wrong in the given demo project.

Creating Transfer Orders gives Error - Company Not found

In Release 5.3 While Creating Transfer Orders automatically (Replenishment to a Transfer Warehouse), the list gets generated but processing gives an error:
Company ID : ### (Branch ID giving the BAccountID ) is not found for
Warehouse ### !
Is there any simple update way to resolve this in v5.3? I did not get this error in release v6.1

Printing barcode in Acumatica reports

I am trying to modify the picklist report and add a barcode, which uses the shipping number.
If i select Barcode and table field in the value propery. I am getting error object reference is not set to instance of an object.
How to print Barcode using table filed value?
If I set Source as Barcode then I am getting the following error
Error: Object reference not set to an instance of an object. Send
Raised At: 10/27/2016 12:34:57 PM Screen: SO.64.40.00
Details:
10/27/2016 12:34:57 PM Error:
Object reference not set to an instance of an object.
If I change it to database, there is no error but it is not displaying barcode
I am just posting the answer as given by Acumatica Support, so that this could help someone in the future.
Use Barcode type: Code128
Use MimeType : image/bmp
Source : Barcode
In the value field, ensure "=" is not used.
Regards
Nandakumar S

Active Reports chartcontrol giving error

I have created a report in Active Reports (.rpx file) which contains a chartcontrol 'ChartControl1'.
Report Datasource is List which contains 'ItemLabel' and 'ItemValue' fields
Script file contains following line of code.
public void ActiveReport_ReportStart()
{
this.ChartControl1.DataSource = rpt.DataSource;
this.ChartControl1.Series[0].ValueMemberX = "ItemLabel";
this.ChartControl1.Series[0].ValueMembersY = "ItemValue";
}
Apparently i am getting an error which says
"DataSource of type System.String is not supported .Parameter name:
genericDataSource"
and this line is causing the problem.
this.ChartControl1.Series[0].ValueMembersY = "ItemValue";
because if i remove this line , there is no error , but report would not render.
I have read that this error is happening due to incorrect binding , but it is not the case here as i have doublechecked it.
What could be the issue?
This error is usually observed when a string value is assigned to the ValueMemebersY property of chart series, where the string value is not a valid field/column name in the table that is bound to the chart as it’s datasource.
Please refer to the walkthrough which describes how to create an unbound bar chart at runtime with SectionReports (Rpx as well as code based)
You can additionally refer the charting sample that is shipped along with ActiveReports.
You may also refer to the following forum post wherein a sample has been attached showing a similar implementation:
http://our.componentone.com/groups/topic/chart-control-throwing-a-binding-error/
Regards,
Mohita
NewtonCode
what version of product are you using? version 7 or 8? Its a bug. we are going to fix it.

Trying to add a field with powershell throws an error

When i'm trying to add a new field, with type Taxonomy (Managed Metadata) via powershell with the method : AddFieldAsXml, It throw me an error :
Error while adding field : Exception calling "AddFieldAsXml" with "1" argument(s): "The object has been updated by another user since it was last fetched."
The weird thing is that I'm adding the field so it can't have been modified or updated by another user ! Can it ?
If you have ideas ?
Thanks

Resources