Can someone confirm the following bug in Office.js on macOS (Microsoft Word)? - ms-word

The following very simple code works fine on Word Online and Word 2016 on Windows 10.
It works the first time it is used on macOS and Word 2016, but then throws an error on any subsequent use...until the page is refreshed and then it works again.
To reproduce:
Open a dialog window using the dialogAPI
Click to close the new window
Click on the button that triggers the opening of the dialog window
On the second attempt no window opens on Mac.
I am on Office Insider Slow running Word for Mac Version 116.13.1 (180523). I have had this issue since a previous release of Office Insider Slow.
The error thrown is:
TypeError: undefined is not an object (evaluating 'dialog.addEventHandler')
It seems that, on a Mac, the dialog object is not closed when the dialog window is closed.
Code:
dialogUrl = dialogUrl + 'qLTI.html';
Office.context.ui.displayDialogAsync(dialogUrl, {height: 90, width: 70},
function (asyncResult) {
dialog = asyncResult.value;
dialog.addEventHandler(Office.EventType.DialogMessageReceived, processMessage);
}
);
Trying to get confirmation and also flag MSFT. Thank you.

This was a known issue to MSFT and was fixed in a June release.
See https://github.com/OfficeDev/office-js/issues/197.

Related

Is there a possibility to close a pyqt dialog in libre office properly (python macro)?

I am trying to write a python macro for libre office 7.4 on windows 10 that creates a dialog with pyqt6.
def open_qt_dialog():
import sys
from PyQt6.QtWidgets import (
QApplication,
QWidget,
)
app = QApplication([])
window = QWidget()
window.setWindowTitle("Simple Dialog")
window.show()
sys.exit(app.exec())
Regardless of whether I use a QDialog or a QMainWindow, I get the following error when I press the "X" button in the title bar. After that the dialog is closed.
com.sun.star.uno.RuntimeException: <class 'SystemExit'>: 0, traceback follows
File "C:\Program Files\LibreOffice\program\pythonscript.py", line 915, in invoke
ret = self.func( *args )
File "C:\Users\<username>\AppData\Roaming\LibreOffice\4\user\Scripts\python\Test.py", line 101, in open_qt_dialog
sys.exit(app.exec())
If I then run the macro again, the dialog is called again and shortly after that libre office crashes. This behavior occurs regardless of whether the macro is executed via the menu or via a button.
Only closing the dialog seems to be a problem. Interaction with libre office (e.g. writing a value into a cell, when pressing a button) works so far.
I already tried to overwrite the closeEvent method using the quit method on the mainwindow. But it just closed (or crashed) the whole libre office application. Do i mess anything?
Do I still have to adjust the sys.exit command in any way? I have the suspicion that sys.exit tries to close libre office completely and not the dialog itsself.
If I run the script via pycharm (connected to uno via uno bridge), then I can close the dialog without any problems.

VS Code terminal showing ERROR on every line with oh-my-posh

My terminal in VS Code has since the previous update shown the word ERROR on every single line. I have installed oh-my-posh a little while back to make the terminal more pleasant to look at and give me some basic information.
Does anyone know where to look, to find the source of the error message? Tyvm :)
Update
Noticed something different when running echo $ as suggested by #kamen-minkov
When I booted Ubuntu up again and my VS Code opened from the previous state it was in the ERROR label was gone:
However. When I opened up a new tab it returned:
The only difference I can notice between the two is that there is a little, unfilled, circle/dot on the left side of the newly opened tab and not the one that opened up with VS Code. Is it some sort of debugger marking or something else? Could it be the source of the problem?
Apparently it's the Shell Integration decorations that's causing the hazards..
// settings.json
"terminal.integrated.shellIntegration.enabled": false,
"terminal.integrated.shellIntegration.decorationsEnabled": "never",
disable these settings and oh-my-posh error label will be gone :)

VSCode Shortcut Ctrl+Shift+e renders as unknown instead of navigating to explorer window

I am trying to navigate to the explorer window via Ctrl+Shift+e but this sequence of keystrokes is not recognizable by VSCode 1.55.2.
I checked this two ways. First, via trying to check what Ctrl+Shift+w and Ctrl+Shift+e were binded to via keyboard shortcuts (Ctrlk, Ctrls) and then recording the keystrokes to reveal what they were binded to.
You will observe that ctrl+shift+w is recognized. Then, in the gif, when I press ctrl+shift+e it renders as ctrl+shift+unknown.
Then, whenever in a saved open file in the editor, when I press ctrl+shift+e hoping that the explorer navigator opens up on the left, that does not happen. Instead the file becomes unsaved with an underscore e appearing in the file.
This is completely new and strange behavior of the editor. I did not encounter this before.
Any help is appreciated.
Edited to add update: VSCode folks indicate that this is a known issue. Ctrl+shift+e translates into insertion of an emoji, it seems. See their comment here.
Same thing happened to me, using linux (ubuntu).
I installed it from the snap store, and tried reinstalling from there and the problem was still there.
Uninstalled and installed it manually from de .deb package at their webpage and it was solved.
Maybe it's an issue they have solved in the latest version (1.15.8) but it's still unsolved in the snap version (1.15.2 in your case, i didn't pay attention on what was my version).
Same problem. Installing vscode from .tar.gz - works perfectly fine, installing from snap leads to unexpected behaviour on Ctrl+Shift+E

Code not showing up when opening Visual Studio from Unity

I am a newcomer when it comes to Unity. I was following along with this online course. At one point, I had to write a C# script. So, I created one and doubled clicked it to edit it with Visual Studio. However when Visual Studio opened, all I could see was a essentially a blank screen. I couldn't see any code. Does anyone know the fix?
Thank you
Did you create it inside like this ... In Unity>ProjectWindow>AssetsFolder>RightClick>Create>C#Script.Then double click to open it.It will open up a script containing Start() and Update() method.If you could not find this.Restart and try.This is to test and try script for Unity scripting.
So this is way too late for the original post but maybe someone else will find this useful. So you did everything you were supposed to and even see the automated code with everything it should have in the inspector, but when you go and run the code whether clicking the actual script in the asset>scripts or clicking the open button in the inspector the same problem persists... blank uneditable screen.
I think you may just need to run updates on Visual Studio and/or if on a Mac maybe you need to log back into Microsoft. To do this just click the Visual Studio tab and click check for updates. Usually, you will also see an update suggestion in the top center of the screen. Run the updates and let it restart visual studio. Once you reopen visual studio at this time if you are on a Mac it should ask you to log into Microsoft. Your code might show up now.

Visual Studio Code window is not appearing

I've encountered a very strange bug with Microsoft Visual Studio Code. I've been using VSCode for a few months now and never had this issue. When I open VSCode, the window just doesn't appear. The app is definitely open, because when I hover over the icon on my taskbar I can see what is being displayed in the app:
Unfortunately, when I click on it, the window does not appear.... I've uninstalled and reinstalled, deleted cache, tried older versions and nothing has worked. Has anyone else encountered this and fixed it? Any advice?
hover over VSCode icon in taskbar
right click on it
click on "New Window"
That should do it.
I had something similar. It appears that the window is just off-screen. I've used my DisplayFusion display manager - to move windows to center/top where I could handle it myself. I expect it'll also work using <Win> + <←> (maximize window to left side of screen).
In my case, the issue went away when uninstalling the GlassIt-VSC extension. I tried modifying the opacity of the window and then it disappeared. I highly suggest you try uninstalling this extension.
In my case I had connected HDMI cable but due to power off my monitor was off, but when I disconnected hdmi cable; VS code visible on my screen.
Got the answer since no one was helping.
Go to view.
Click solution explorer.
It should show the name of your project.
Click the small arrow at the beginning of the heading of your project.
Click source files.
Click yourproject.cpp.
Thank you.
I encountered a similar issue with a plugin called GlassIt while I was playing with a property called "glassit.alpha" somehow it went to 1 (possibly I changed it accidentally) and nothing showed up. (here's an image where you can slightly see that I set alpha to 20)
what i did was to just edit the %appdata%\..\Roaming\Code\User\Settings.json and set "glassit.alpha": 1, to 255
UPDATE I just realised there was already an answer I didn't see while I was writing this post
I had this issue during a remote desktop session and could bring the VSC window back via hitting F11 (via the onscreen keyboard in my case, since the F11 key on my keyboard was being captured by the host system).
In my case, I have a dual monitor setup, and the laptop was in clamshell mode. However, the laptop's built-in monitor was recognized as a third monitor, and VsCode was going there.