This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Read/Write multiselect property

Former Member
Former Member
Guys, I again need your help. I'm going crazy with a (i think simple) problem, maybe you can help me out?
I've got a "onboarding" document, containing a multi-select property called "Department". It's a simple "choose from list Departments (multiselect).
At the And of the Onboarding, I create a Employee Object in the workflow and "copy" some of the onboarding property values. That works fine! I can copy text and single select (lookup).

What drives me crazy is to read a multiselect and write the same values to the "same" property in the new employee object.

I tried alot... at the moment i try it this way:

Read Multi-Select property

...
' Abteilung/Department
Dim ilookups_abteilung : set ilookups_abteilung = PropertyValues.SearchForProperty(1234).TypedValue.GetValueAsLookups
...


Write to the new object

...
' Abteilung
oPropVal.PropertyDef = 1234
oPropVal.TypedValue.SetValue MFDatatypeMultiSelectLookup, ilookups_abteilung
oPropValues.Add -1, oPropVal
...


That gives me a "type conflict"
What's the problem?
Regards
Chris
Parents
  • Former Member
    Former Member
    Dear Craig,
    during my research of the m-files API i even found your posting where you described the "first steps" with VAF. It looked interesting but as a absolute beginner i had two problems.

    1. I din't understand exactly what the VAF is and how it works.
    For me it looked like applications, developed in visual studio, that are (after compiling) installed on the m-files server and running there in some way?. When i got it right, the advantage is that many bennefits of Visual Studio can be used (f.e. code debugging).
    From my flat point of view this seemed to be a little bit "overkill" if I only want to do some simple operations during workflow changes, for example. Set some properties, create a object...? Maybe I can't see the big picture at the moment? ;) Is it overkill or the best tool for daily scripting work?

    2. I couldn't get it to work!
    I downloaded this "inofficial m-files api template" for Visual studio, but i didn't get it installed.
    Even for me it felt like the M-Files company isn't really interested in taking "normal" users by the hand and leading them into API development, maybe I'm wrong here?

    In my perception the absoulte best demonstration of the VAF would be a 5 minute youtube screen-recorded clip, showing how to install the api tamplate and creating a "hello world" application. Or setting some properties in the demo vault. Step by step That would be heaven!
    The first steps are the hardest ;)
Reply
  • Former Member
    Former Member
    Dear Craig,
    during my research of the m-files API i even found your posting where you described the "first steps" with VAF. It looked interesting but as a absolute beginner i had two problems.

    1. I din't understand exactly what the VAF is and how it works.
    For me it looked like applications, developed in visual studio, that are (after compiling) installed on the m-files server and running there in some way?. When i got it right, the advantage is that many bennefits of Visual Studio can be used (f.e. code debugging).
    From my flat point of view this seemed to be a little bit "overkill" if I only want to do some simple operations during workflow changes, for example. Set some properties, create a object...? Maybe I can't see the big picture at the moment? ;) Is it overkill or the best tool for daily scripting work?

    2. I couldn't get it to work!
    I downloaded this "inofficial m-files api template" for Visual studio, but i didn't get it installed.
    Even for me it felt like the M-Files company isn't really interested in taking "normal" users by the hand and leading them into API development, maybe I'm wrong here?

    In my perception the absoulte best demonstration of the VAF would be a 5 minute youtube screen-recorded clip, showing how to install the api tamplate and creating a "hello world" application. Or setting some properties in the demo vault. Step by step That would be heaven!
    The first steps are the hardest ;)
Children
No Data