stevencohn / OneMore

A OneNote add-in with simple, yet powerful and useful features
Mozilla Public License 2.0
2.45k stars 208 forks source link

Are no commands able to be executed on the page uploaded to OneDrive? #1433

Open ILCNa opened 1 month ago

ILCNa commented 1 month ago

This is my first time providing feedback on the GitHub platform, and my English skills still have room for improvement. Please forgive any mistakes, and I sincerely appreciate your contributions to the community.

I spent several hours trying to solve this issue that seems to affect only me. I felt it was necessary to report it to you.

Problem to Solve

An error occurred when I tried to use most commands on the OneDrive uploaded note page.

To Reproduce

Steps to reproduce the behavior:

1.Open a note uploaded to OneDrive, and you'll often notice the following graphical differences compared to the local file (with the OneDrive file on top and the local file below). image1 You can display the image mentioned above by going to File -> Information(?).It easy to be found. 2.The most obvious issue is that I can't use the functions circled in the image(Not including "剪切(T)"). image2 When I try to use them, an error message pops up like this: image3 image4 image5 As shown in the first image, means "An error occurred while executing the AddCaptionCommand command. Please refer to the log file for detailed information."

Expected Behavior

All notes can execute commands normally, not just the local "TEST" note. image6

Environment (if applicable)

OneNote Version: Microsoft® OneNote® is compatible with Microsoft 365MSO (Version 2405 Build 16.0.17628.20006) 64-bit. OneMore Version: 6.4.0 or 6.3.1

Additional Context

Here is the log.

14|01:10:06.797| Running command AddCaptionCommand 10|01:10:06.844| ..error getting page {62B360F3-D970-492C-9759-A46CFA1561D2}{1}{E1952170721748302593951910932405542919089991}

I think the problem lies here; oneMore may not be able to handle files uploaded to OneDrive properly. I noticed that the note files in OneDrive are in Internet Shortcut (.url) format. image7 System.Xml.XmlException Message: “"”(十六进制值 0x22)是无效的字符。 第 2 行,位置 705。 Source: System.Xml StackTrace: 在 System.Xml.XmlTextReaderImpl.Throw(Exception e) 在 System.Xml.XmlTextReaderImpl.ParseAttributeValueSlow(Int32 curPos, Char quoteChar, NodeData attr) 在 System.Xml.XmlTextReaderImpl.ParseAttributes() 在 System.Xml.XmlTextReaderImpl.ParseElement() 在 System.Xml.XmlTextReaderImpl.ParseElementContent() 在 System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r) 在 System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r, LoadOptions o) 在 System.Xml.Linq.XElement.ReadElementFrom(XmlReader r, LoadOptions o) 在 System.Xml.Linq.XElement.Load(XmlReader reader, LoadOptions options) 在 System.Xml.Linq.XElement.Parse(String text, LoadOptions options) 在 River.OneMoreAddIn.OneNote.d__48.MoveNext() TargetSite: [System.Xml] System.Xml.XmlTextReaderImpl::Throw()

10|01:10:06.844| 运行命令AddCaptionCommand时出错 10|01:10:06.844| System.NullReferenceException Message: 未将对象引用设置到对象的实例。 Source: River.OneMoreAddIn StackTrace: 在 River.OneMoreAddIn.Commands.AddCaptionCommand.d2.MoveNext() --- 引发异常的上一位置中堆栈跟踪的末尾 --- 在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 在 River.OneMoreAddIn.Commands.AddCaptionCommand.d2.MoveNext() --- 引发异常的上一位置中堆栈跟踪的末尾 --- 在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 在 System.Runtime.CompilerServices.TaskAwaiter.GetResult() 在 River.OneMoreAddIn.CommandFactory.d5.MoveNext() TargetSite: [River.OneMoreAddIn] River.OneMoreAddIn.Commands.AddCaptionCommand+d2::MoveNext()

stevencohn commented 2 weeks ago

Hello. In your last image, you show a screenshot of the Properties of the shortcut. It is marked Read Only. Can you untick that checkbox, click OK, and then try the OneMore commands again please>

ILCNa commented 2 weeks ago

Hello. In your last image, you show a screenshot of the Properties of the shortcut. It is marked Read Only. Can you untick that checkbox, click OK, and then try the OneMore commands again please>

Hello, I have disabled the read-only option for the shortcut and still cannot use the commands.

stevencohn commented 2 weeks ago

There's nothing here that looks out of the ordinary. All commands should work equally for both local and remote notebooks.

If you can, please Zip and attach the OneMore log file. You can find it at %TEMP%\OneMore.log

ILCNa commented 2 weeks ago

There's nothing here that looks out of the ordinary. All commands should work equally for both local and remote notebooks.

If you can, please Zip and attach the OneMore log file. You can find it at %TEMP%\OneMore.log

of course :) OneMore.zip

stevencohn commented 1 week ago

@ILCNa Most of the errors in your log indicate that there is at least one corrupt page, having a misplaced double quote. At least this is how OneNote is handing over the page, as an XML document, to OneMore; and then OneMore can't parse the invalid XML.

I'm not sure if this is due to the multi-lingual content, running on a machine configured with Chinese, or something else. Sadly, I don't know Chinese so would find this impossible to diagnose.

I'll leave this ticket here in case I think of a way to approach it. Sorry for the inconvenience.

ILCNa commented 1 week ago

@ILCNa Most of the errors in your log indicate that there is at least one corrupt page, having a misplaced double quote. At least this is how OneNote is handing over the page, as an XML document, to OneMore; and then OneMore can't parse the invalid XML.

I'm not sure if this is due to the multi-lingual content, running on a machine configured with Chinese, or something else. Sadly, I don't know Chinese so would find this impossible to diagnose.

I'll leave this ticket here in case I think of a way to approach it. Sorry for the inconvenience.

OK, thanks for your efforts