[JW Lua] JW Lua to change pitch wheel value

Undoaudio undoaudio at gmail.com
Thu Dec 12 09:26:22 CET 2019


I've been looking at them while trying to figure this out and while I have
an idea of what should be possible I have very little clue how to get
there. My skillset in coding is almost non-existent so even if I might have
a hunch what classes, properties etc. to try, I rarely get the code
working. I'm sorry to bother with such basic stuff but I guess everyone has
to start somewhere. Anyway, I'm really thankful for all the help and tips
I've gotten!

ke 11. jouluk. 2019 klo 23.31 Jan Angermüller (jan at angermueller.com)
kirjoitti:

> Please have a look at JW Lua's "Class Browser" (click on the "Class
> Browser..." button at the left bottom of the development window and go to
> FCMidiExpression). This usually gives you an idea of what is possible. The online
> documentation <http://www.finaletips.nu/frameworkref/annotated.html> is
> also very helpful.
> If you want the value for a certain region only, you should probably use
> the MeasurePos property (for the start position) and add another
> FCMidiExpression at the end position.
>
> Jan
>
> Am 11.12.2019 um 22:18 schrieb Undoaudio:
>
> Okay, this is getting me quite close! The only thing I think is missing
> from what I need is the possibility to write/change the pitch wheel data
> for the selected region only, not necessarily for whole measures.
> Sometimes I need to bend eg. one 16th note a 1/3 tone down and the next
> one a quarter tone up. I tried to figure this out but didn't get it to
> work. If you can steer me in the right direction I'd be most grateful.
> Actually I already am.
>
> Thanks so much!
>
> ti 10. jouluk. 2019 klo 21.02 Chris (marcel.denio at gmail.com) kirjoitti:
>
>> This script creates a pitch wheel event for each measure in the selection
>> (it's just to show you how to create an event)
>>
>> ------------
>> local musicregion = finale.FCMusicRegion()
>> musicregion:SetCurrentSelection()
>> if musicregion:IsEmpty() then return end
>>
>> for m, s in eachcell(musicregion) do
>>     -- 'm' is the measure number, 's' is the staff number/ID
>>     local cell = finale.FCCell(m, s)
>>     local me = finale.FCMidiExpression()
>>     me:ConnectCell(cell)
>>     me:SetUsePitchWheel()
>>     me.PitchWheelValue = 1000
>>     me:SaveNew()
>> end
>> ------------
>>
>> Chris
>>
>> _______________________________________________
>> JWLua mailing list
>> JWLua at jwmusic.nu
>> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
>>
>
> _______________________________________________
> JWLua mailing listJWLua at jwmusic.nuhttp://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
>
>
> _______________________________________________
> JWLua mailing list
> JWLua at jwmusic.nu
> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20191212/5229f700/attachment.htm>


More information about the JWLua mailing list