Working with “Out” Parameters in JavaScript

后端 未结 3 1844
星月不相逢
星月不相逢 2020-12-11 03:08

I am working with an ActiveX control in Internet Explorer 8 that is to display a save file dialog which let\'s the user choose a file name and file type (jpg, gif, etc). Th

3条回答
  •  清歌不尽
    2020-12-11 03:37

    All function arguments in JavaScript are passed by value (even if the value being passed is a reference to an object (which it is)). There is no pass-by-reference.

    If SaveFileDialog modifies the objects referenced by saveFileName and saveFileType then you have access to those changes through your existing variables.

提交回复
热议问题