Thank's for replying I solve my issue by setting directly the Info property
and not using the setPropertyValue.
I replaced dataSource.setPropertyValue("Info", cProps); by dataSource.info
= cProps;
2009/7/14 Joachim Lingner <[email protected]>
>
>
>
> ---------- Message transféré ----------
> From: Joachim Lingner - Sun Germany Software Engineer - ham02 - Hamburg
> <[email protected]>
> To: [email protected]
> Date: Tue, 14 Jul 2009 09:27:04 +0200
> Subject: Re: [udk-dev] Create a uno sequence<>
> You probably need to use value objects within the array. See here
>
>
> http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/ProUNO/Bridge/Mapping_of_Sequence
>
>
> Joachim
>
>
> Marc MAUZOLE wrote:
>
>> Hi,
>>
>> I'm trying to automate a mail merge with JavaScript, but I can't use the
>> methode setPropertyValue when the parameter is a Sequence<any>, I always
>> get
>> a com.sun.star.lang.IllegalArgumentException. I read that JavaScript array
>> are not SAFEARRAY so I tried in VBS but I had the same exceptions.
>> Somebody
>> can help me ?
>> Thanks a lot,
>> Marc
>>
>> Here are some JavaScript code examples :
>>
>> var dataSource = dbContext.createInstance();
>> var p0 = wdApp.Bridge_GetStruct("com.sun.star.beans.PropertyValue");
>> var cProps = new Array();
>> p0.Name = "Extension";
>> p0.Value = "csv";
>> cProps[0] = p0;
>> dataSource.setPropertyValue("Info", cProps);
>>
>> or
>>
>> var tableFlt = new String();
>> tableFlt[0] = "TABLE";
>> dataSource.setPropertyValue("TableTypeFilter", tableFlt);
>>
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>