Desktop version

Main > Forum > 1C:Enterprise Platform > 1C:Query language and DCS > DocumentForm -> Report parameter "Ref"

Forum

Search UsersRules
DocumentForm -> Report parameter "Ref"
#1
Active user
Points:: 0
Joined:: Sep 18, 2012

Hello everyone,
I've got DocumentForm where I created command. Now I want to open report fr om this form with report's parameter filled using Object.Ref of document.
Command button triggers something like this:

Code
&AtClient
Procedure OpenReport(Command)
   Filter = New Structure("Ref",Object.Ref);
   FormParameters = New Structure("GenerateOnOpen, Filter, VariantKey",True,Filter,"Default");
   OpenForm("Report.ZlecenieNaprawyPodsumowanie.ObjectForm",FormParameters,ThisForm,ThisForm);
EndProcedure


The object form of report opens after clicking button but Ref parameter of report has no value, it is not filled. How should I open it so the report knew the value of document Reference? So that user could click button at document and see report data linked with this document?

MainDataCompositionSchema of report has query where is written:
Code
"... WHERE Document.Ref = &Ref"

I just want to see only &Ref data in report after calling command at documents form.
Thank you for any help.
Kris

Profile
#2
Active user
Points:: 0
Joined:: Oct 4, 2018

Hello, Kris!
I think you should use "Report.ZlecenieNaprawyPodsumowanie.Form" instead of "Report.ZlecenieNaprawyPodsumowanie.ObjectForm".

Profile
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)



© 1C LLC. All rights reserved
1C Company respects the privacy of our customers and visitors
to our Web-site.