Desktop version

Main > Forum > 1C:Enterprise Platform > Studying 1C:Enterprise platform > 1C Drive-Extension, TransferNewDocument

Forum

Search UsersRules
1C Drive-Extension, TransferNewDocument
#1
Interested
Points:: 0
Joined:: Sep 30, 2020

Hello,I have created an extension in 1C Drive and created a lot of documents.I want to transfer document data to another document.I can do it in 1C Enterprise but when I tried to do it in 1C Drive extension,I couldn't.Is it possible transfer new document in 1C Drive-Extension?

I added two pictures below.

Profile
#2
Administrator
Points:: 0
Joined:: Oct 3, 2019

Hello Mesut,

let's start over.

You created an extension, then you added an existing document to this extension.

Is everything working correctly up to this point?

Further, it's not clear for me what data you want to transfer from one document to another?


Best,
Aleksandr

Profile
#3
Interested
Points:: 0
Joined:: Sep 30, 2020

Not existing.I have created external documents in extension.

I want to transfer tabular section or other values to another document in extension.
I have set all things,you can see pictures below.Sorry for turkish picture.

Transfer new document button is shown in designer but when I run the program, the button is not shown.

Profile
#4
Administrator
Points:: 0
Joined:: Oct 3, 2019

Mesut,

please attach your dt-file with the extension. I'll see what's wrong.

Aleksandr

Profile
#5
Interested
Points:: 0
Joined:: Sep 30, 2020

I have send you dt and cf file,please control your mail.A mail must be from mesutkahraman111@gmail.com

Profile
#6
Administrator
Points:: 0
Joined:: Oct 3, 2019

Dear Mesut,

in 1C extensions, the input mechanism based on (when a new document is filled with data from another, previously entered document) is implemented differently, not like in the main program.

First, you need to create a new general command in the extension (please see screen 1).

To process this command, create the following code:

Code
&AtClient
Procedure CommandProcessing(CommandParameter, CommandExecuteParameters)
   // Insert handler content.
   refSepetleme   = New Structure("Ref", CommandParameter);
   FormParameters    = New Structure("FillingValues", refSepetleme);
   
   OpenForm("Document.AsidikYağ_Alma.ObjectForm", FormParameters, CommandExecuteParameters.Source, CommandExecuteParameters.Uniqueness, CommandExecuteParameters.Window, CommandExecuteParameters.URL);
EndProcedure



and in the document module "AsidikYağ_Alma" - this is the filling procedure:

Code
Procedure Filling(FillingData, StandardProcessing)
   
   If TypeOf(FillingData) = Type("Structure")
      AND FillingData.Property("Ref")Then
   
      If TypeOf(FillingData.Ref) = Type("DocumentRef.Sepetleme") Then
         
         docSepetlemeRef = FillingData.Ref;
         
         SepetlemeReferans = docSepetlemeRef;
         
         SepetSıraNo = docSepetlemeRef.SepetSıraNo;
         For Each CurRowMalzemeBilgi In docSepetlemeRef.MalzemeBilgi Do
            
            NewRow = MalzemeBilgi.Add();
            NewRow.BoyaCinsi = CurRowMalzemeBilgi.BoyaCinsi;
            NewRow.BoyaFirması = CurRowMalzemeBilgi.BoyaFirması;
            NewRow.FirmaAdı = CurRowMalzemeBilgi.FirmaAdı;
            NewRow.GirişTarihi = CurRowMalzemeBilgi.GirişTarihi;
            NewRow.Kg = CurRowMalzemeBilgi.Kg;
            NewRow.MalzemeAdedi = CurRowMalzemeBilgi.MalzemeAdedi;
            NewRow.MalzemeBoyu = CurRowMalzemeBilgi.MalzemeBoyu;
            NewRow.MalzemeÇevresi = CurRowMalzemeBilgi.MalzemeÇevresi;
            NewRow.MalzemeNo = CurRowMalzemeBilgi.MalzemeNo;
            NewRow.RalKodu = CurRowMalzemeBilgi.RalKodu;
            NewRow.Yüzey = CurRowMalzemeBilgi.Yüzey;
            
         EndDo;
         
      EndIf;
      
   EndIf;
   //}}__CREATE_BASED_ON_WIZARD
EndProcedure


after these changes everything works (screenshots 2 and 3).

Best,
Aleksandr

Profile
#7
Interested
Points:: 0
Joined:: Sep 30, 2020

Ok.Can you send me dump with these changes.

Mail:mesutkahraman111@gmail.com

You can send it with zip in https://wetransfer.com/

Profile
#8
Administrator
Points:: 0
Joined:: Oct 3, 2019

Dear Mesut,

https://dropmefiles.com/0rJeJ

Profile
#9
Administrator
Points:: 0
Joined:: Oct 3, 2019

Dear Mesut,

sent you an example.

Aleksandr

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.