How to get a Xojo app in the Windows Store

Public Function APIMsgBox(MyHandle as Int32, TextIn as String, MyCaption as String, uType as Int32) as Int32 #If TargetWindows Declare Function MessageBox Lib "User32.dll" Alias "MessageBoxA" (hWnd as Int32, lpText as CString, lpCaption as CString, AType as Int32) as Int32 If System.IsFunctionAvailable("MessageBoxA","User32.dll") Then Return MessageBox(MyHandle, TextIn, MyCaption, uType) Else //There was an error End If #Endif End Function

[code]Sub Action() Handles Action
//https://msdn.microsoft.com/en-us/library/windows/desktop/ms645505(v=vs.85).aspx
Const MB_ICONWARNING = &H30
Const MB_CANCELTRYCONTINUE = &H2
Const MB_DEFBUTTON2 = &H100

Dim MyResponse as Int32
MyResponse = APIMsgBox(Window1.Handle, “Resource not Available. Try again?”, “Account Details”, Bitwise.BitOr(MB_ICONWARNING, Bitwise.BitOr(MB_CANCELTRYCONTINUE, MB_DEFBUTTON2)))
//Another example
'MyResponse = APIMsgBox(Window1.Handle, “My New Message”, “My Caption”, MB_ICONWARNING)

If MyResponse = 5 then //IDIGNORE
//The Ignore button was pressed
ElseIf MyResponse = 4 then //IDRETRY
//Retry button was pressed
ElseIf MyResponse = 3 then //IDABORT
//Abort button was pressed
End If

End Sub[/code]

Here is an example project in case I mis-typed something.

MsgBoxAPI download Link

Here is a free download with steps to: Build an AppX Installer for Microsoft Store with Xojo Many thanks to @Michel Bujardet and @David Cox for their generous tips and tricks.

[quote=314772:@Eugene Dakin]Public Function APIMsgBox(MyHandle as Int32, TextIn as String, MyCaption as String, uType as Int32) as Int32

Here is an example project in case I mis-typed something.

MsgBoxAPI download Link[/quote]

Thank you so much Eugene.

Now, something else about getting in the Windows Store that is worth noting. Nothing technical, but maybe important to mention.

All apps that collect financial data must be sold through a business account. When I started 3 years ago I had a personal account. Since Check Print’R and Check Writer III indeed collect financial data, I had to buy a business account ($99, same price as the MAS), and the store support graciously migrated all my apps.

If anybody does stuff like personal budget or financial stuff, it is better to start off with a business account.

Note that contrary to the MAS, they won’t bother with a D.U.N number. However, for Europeans, a VAT number is required.

Please do not use MessageBoxA, but MessageBoxW for unicode support.

Your right Christian. My apologies as this should be MessageBoxW for 32 bits.

I’m a bit late to this as I’ve been away for a few days.

I think the following is the correct declare which will cover you for both 32 and 64 bit.

Declare Function MessageBox Lib "User32.dll" Alias "MessageBoxW" (hWnd as Integer, lpText as WString, lpCaption as WString, AType as UInt32) as Int32

See https://msdn.microsoft.com/en-us/library/windows/desktop/ms645505(v=vs.85).aspx and http://blog./2017/01/22/windows-to-xojo-data-type-conversion/ for more information.

Hello,

I used the documentation from Eugene to prepare my first app. t works fine, till uploading to Microsoft. Here I get the following error messages

[code]Package acceptance validation error: You don’t have permissions to specify the following namespaces in the appx manifest file of the package WinProLi.appx: restricted namespace: http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities

Package acceptance validation error: Your developer account doesn’t have permission to submit apps converted with the Desktop Bridge at this time. https://aka.ms/desktopbridgeforwindowsstore[/code]

I wrote to Microsoft, but didn’t get am message within 6 days. Does some has an idea where the problem is?

Hi Manfred,

I had this comment for a while when I submitted my first app, and as painful as this is to say, the answer is to ‘wait’. There will be a company that will be verifying your program and once verified, then you will not need to go through this waiting-step any longer. One of the many things that they will be checking is your Windows Store Privacy Statement, and here is a link to mine: Privacy Statement.

It is really exciting to get your app in the Windows store, and this does take a while, and I recall my first time required about 2-weeks.

thank you. So I know to continue waiting. Meanwhile I can prepare my other applications. They need a minimal adaption, because they need a registration in the download version. Like the versions in the Mac Store I wants the payment with the Microsoft Store. So, I have to change it a little bit.

And also I can add the privacy side for them in my homepage.

Meanwhile I have contact to a Microsoft member. And I’m a few steps before bringing my first app to the store.

Yesterday he told me, that I should remove the files MSVCP140.DLL and VCRUNTIME140.DLL from the package. I tried it yesterday, but my app doesn’t start without these files. I think these are hardcoded in the output. So I asked him if this is necassey. And today I got the answer that it goes on with the file.

Nevertheless I wants to ask here, if some was able to start a Xojo Windows app without these files.

Today, I was able to upload my Program WinProLi. Now, I’m waiting for the certification. I hope this will be good.

And what happened with the MSVCP140.DLL and VCRUNTIME140.DLL files?

They accepted it. Bit nevertheless I wants to remove it - if it is possible. Till now I have no idea…

Why remove MSVCP140.DLL and VCRUNTIME140.DLL if your program needs it ? In all my Windows Store programs, I keep the DLLs necessary for Xojo executable. I had the issue long ago with the Desktop Converter, I am not ready to inflict myself more pain.

The member of Microsoft told me, that these files will be installed automatic during the installation of the app if it is necessary. And I understand that it is normally better to do this central instead by each application. But he accepted, that my app needs it.

Now I’m fin the certification state and prepare the next app.

Today, my first App “WinProLi” received the store. It took more then 2 weeks from uploading till going to store. The next two ones are in the pipe and the fourth will be made ready for uploading in the next days.

I thank all people in the forum and specially Eugene Dakin, Michel Bujardet and David Cox for the documentation.