• 10.06.2024, 23:38
  • Register
  • Login
  • You are not logged in.

 

Dear visitor, welcome to Aqua Computer Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

AquaSuite crashing on XML code change

Tuesday, January 31st 2023, 5:56am

Firstly, I know I did a stupid thing. That's what happens when you've worked a night shift then decide to change something on your computer.

I wouldn't mind knowing if there's a way to fix this that doesn't loose all but the last change of my Aquasite pages.

First step was to create a software sensor to report the max speed of all my CPU cores, in GHz.

I added a small control to show the max speed of the CPU cores in my overview page called "Quadro". I wasn't happy as the control shows frequency to the nearest whole number.

stupidly I tried modifying the xml code to show one decimal point, by editing the xml directly. There is no way in the control settings to edit this outside of the XML tab of the control. The check code button reported no errors, but when I pressed "OK" in the dialog and went back to the main page, the control changed to all red, no information was displayed and then a short time later the software crashed.
Now, whenever I go to that overview page, the software crashes. I assume I made a mistake in the XML code which wasn't picked up by the code checking. Unfortunately I can't get into the code to post it as the software crashes shortly after opening the "Quadro" overview page.

Is there a way to get into the xml of the control I changed and change it back without starting the aquasuite software?
And yes, I know I should have created a backup of the page before making changes, and would have if I hadn't have finished a night shift this morning and not slept properly yet.

I'm using X.51 if that makes a difference. I've had a quick search of this forum and haven't found an English page that seems to explain this issue.


Thanks for helping a stupid, tired idiot! :S

Trev

Tuesday, January 31st 2023, 7:32am

You have to delete this Page.
When you work with Custom items. Edit the element on a new page and if everything works, copy it to the final page.

Wednesday, February 1st 2023, 2:49am

With a full nights rest I work out a fix.

I exported the page, then edited the resultant .page document in a text editor to change back the xml code I initially changed.

Then I imported the page into a new Overview page and after checking that it worked, I deleted the old one.


Any ideas on how to edit the control's xml code to add two decimal points? The relevant code (I think!) is this:


<TextBlock
FontSize="24"
HorizontalAlignment="Center" VerticalAlignment="Center">
<TextBlock.Text>
<MultiBinding Converter="{StaticResource UnitConverter}" ConverterParameter="0">
<Binding ElementName="this" Path="DataContext.Data"/>
<Binding ElementName="this" Path="DataContext.Data.v"/>
</MultiBinding>
</TextBlock.Text>
</TextBlock>

Just not sure how to change the xml code to add decimal points and a quick search doesn't find an explaination of the UnitConverter resource.

Stephan

Administrator

Wednesday, February 1st 2023, 3:53pm

Try to add

<Binding.StringFormat>
{}{0:0.00}
</Binding.StringFormat>

after End of the Multibinding block

demilleroh

Junior Member

Made XAML Change to Auto-loaded Page

Thursday, February 9th 2023, 3:57pm

Hello,
I had a similar experience. I made an XAML change on a page which was set to load automatically. The XAML code-check was fine, but AquaSuite would just disappear when I activated the code. Restarts of AquaSuite would of course then fail, too.

Fortunately, I tried something that worked. Immediately after AquaSuite came up I selected a different page manually and that intercepted and stopped the automatic load of the failing page. I was then able to proceed to fix the change to the XAML code.

Friday, February 24th 2023, 1:59am

Hi Stephan,

Do you mean like this code? (attachment CodeBlock.jpg)
I can't get the code block in the forum to work properly, it doesn't line space properly and deletes parts of the code. Sorry.
If it's important, I've spaced across for the indentations, because I couldn't get the tabs into the code block, it would just switch the control focus.


When I check syntax, I get a number of errors: (attachment Check Code.jpg)


apologies for the snip, it's the quickest way I could think of to get the dialog info into the post. I've been caught up at work and therefore a little tardy with trying this code on my machine.

It appears to be an error on the line, and I'm not familiar in XML in any way. (R, Python, C, 6800 ASM, + many other 'old school' langs I've used, just not the new ones!)
Thanks for your help,
Trev
BigTrev has attached the following files:
  • CodeBlock.jpg (96.56 kB - 39 times downloaded - Last download: Mar 8th 2024, 4:11am)
  • Check Code.jpg (28.93 kB - 32 times downloaded - Last download: Apr 11th 2024, 8:30pm)

Friday, February 24th 2023, 7:27am

Any ideas on how to edit the control's xml code to add two decimal points? The relevant code (I think!) is this:
ConverterParameter="2"


Sets the Parameter to 2 == 2 decimal places.





StringFormat is not working when you use an converter.

Wednesday, March 15th 2023, 12:25am

Thanks,

That fixed it!

Trevor