You can send the image data directly down in a string field. Or you can use my little json trick too.
About 25 images, cant remember an exact amount
Since this is not a BAQ Report, your options are more limited for retrieval.
I would recommend using my json trick and pulling them by index in the report.
If you have some identifying information beforehand, you could avoid sending all 25 images down.
Little JSON trickā¦
I hate that things which should br simple areā¦difficult!
Only ID i have is the name of the imageā¦
Configurator dropdown 1 chooses the type of profile
Configurator dropdown 2 chooses the number of safety edges (1 2 or both) those two combined makes the image stringā¦ InternalAngleB
Luckily itās not real hard.
Little BPM on the SubmitToAgent or whatever to grab the images and shove them in the report data.
Harder to do in an RDD report, (since you gotta find somewhere to stick it) but should be easy once they fix that Call Context bug.
Do you have a link to your trick or could you hint what i need to search for?
Yeah, Iām looking it up and thinking at the same time. Doesnāt work well
I think CallContextBPMData is only broken from the web side, so let me do a test to see if it will flow down from a bpm to the Job Traveler.
No, but thatās a good one lol. Some of the techniques might be needed to grab the data lol.
I meant this one:
Ok, test done.
I put something in the CallContextBPMData
in a pre-processing directive on SubmitToAgent for the Job Traveler.
I then added a DataSet and a field in the report and drug it to the header.
="
SELECT T1.Character01
FROM CallContextBPMData_" + Parameters!TableGuid.Value + " T1"
And it came through:
So yes we can send them on down.
You wanna pull and send all of them, or do you have enough info to pull the right one upfront in the BPM and just send that?
Literally the only thing i have is the filename theres nothing else i can reference based on how the configurator has been setup
Thatās fine, Iām just wondering if we could figure out the filename before the report is run so we donāt have to send down 25 images and screw with embedded code.
How does the traveler know which image to pull?
Iām asking that specific question so we can write a linq query to get the image name, then grab that image data to send down.
The configurator generates the string, i am then writing that to the jobhead.userchar1 field using document rules
The configurator does some magic with a lookup table to display the image on the configurator itself but its very straight forward how that works
And those images are stored in image maintenance?
yes sir!
just counted, theres a total of 33 images
The SubmitToAgent has a āJobsā field, does anyone know if thatās a delimited field?
If we need to make it work for Mass Prints, it gets slightly more complicated.
IF that field is not delimited, all we need to do is this to get the data down to the report.
You could add some error checking.
Pre-Processing on Erp.Rpt.JobTrav.SubmitToAgent
//Ref: Erp.Contracts.BO.Image
CallService<ImageSvcContract>(img =>
{
var job = Db.JobHead.FirstOrDefault(x => x.JobNum == ds.JobTravParam.FirstOrDefault().Jobs);
if(job == null) return;
byte[] image = img.GetOriginalImage(job.UserChar1);
callContextBpmData.Character01 = Convert.ToBase64String(image);
});
Then you can do this:
In the report, add a DataSet, call it CallContextBPMDataOrSomethingLOL
- Use a data source in the report.
Query expression ā
="
SELECT T1.Character01
FROM CallContextBPMData_" + Parameters!TableGuid.Value + " T1"
Add a field for it.
Then add the image and set it up like this:
If that Jobs
field turns out to be a delimited field, weāll have to do something a little different.