[GH-ISSUE #222] Unable to find qml.net library on Windows Server 2012 R2 #142

Closed
opened 2026-05-05 11:06:40 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @lilongueti on GitHub (Aug 26, 2020).
Original GitHub issue: https://github.com/qmlnet/qmlnet/issues/222

the files it need seem to have downloaded properly on C:\users\Administrador.qmlnet-qt-runtimes
based on #173 i'm including the info i guess you'll be asking for
here's enviroment variables

USERNAME: Administrador
PROCESSOR_LEVEL: 6
LOGONSERVER: \\SERVIDORAD
HOMEPATH: \Users\Administrador.MONTANA
PATHEXT: .COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
ProgramData: C:\ProgramData
HOMEDRIVE: C:
ProgramFiles: C:\Program Files
TEMP: C:\Users\ADMINI~1.MON\AppData\Local\Temp\1
USERDNSDOMAIN: MONTANA.LOCAL
PROCESSOR_REVISION: 3f00
ProgramW6432: C:\Program Files
SystemDrive: C:
CommonProgramW6432: C:\Program Files\Common Files
PROCESSOR_ARCHITECTURE: AMD64
Path: C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System3
2\WindowsPowerShell\v1.0\;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\
Binn\;c:\Program Files\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files\Mic
rosoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\150\
DTS\Binn\;C:\Program Files\Symantec.cloud\PlatformAgent\;C:\Program Files (x86)\
Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files (x86)\
Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\dotnet\
PSModulePath: C:\Windows\system32\WindowsPowerShell\v1.0\Modules\
CommonProgramFiles: C:\Program Files\Common Files
ALLUSERSPROFILE: C:\ProgramData
ComSpec: C:\Windows\system32\cmd.exe
ProgramFiles(x86): C:\Program Files (x86)
USERDOMAIN_ROAMINGPROFILE: MONTANA
USERPROFILE: C:\Users\Administrador.MONTANA
SESSIONNAME: RDP-Tcp#24
CLIENTNAME: YSERA
USERDOMAIN: MONTANA
FP_NO_HOST_CHECK: NO
CommonProgramFiles(x86): C:\Program Files (x86)\Common Files
COMPUTERNAME: SERVERSUMMA
windir: C:\Windows
NUMBER_OF_PROCESSORS: 4
PROCESSOR_IDENTIFIER: Intel64 Family 6 Model 63 Stepping 0, GenuineIntel
APPDATA: C:\Users\Administrador.MONTANA\AppData\Roaming
LOCALAPPDATA: C:\Users\Administrador.MONTANA\AppData\Local
TMP: C:\Users\ADMINI~1.MON\AppData\Local\Temp\1
SystemRoot: C:\Windows
PUBLIC: C:\Users\Public
OS: Windows_NT

Program.cs

using System;
using System.IO;
using Qml.Net;
using Qml.Net.Runtimes;

namespace ActualizadorAdvanced
{
    class Program
    {
        static int Main(string[] args)
        {
            foreach(System.Collections.DictionaryEntry Variable in Environment.GetEnvironmentVariables())
            {
                System.Console.WriteLine(Variable.Key.ToString()+ ": " +Variable.Value);
            }
            RuntimeManager.DiscoverOrDownloadSuitableQtRuntime();
            System.Console.Read();
            if(args.Length==0)
            {
            
            
            QQuickStyle.SetStyle("Material");

            using (var application = new QGuiApplication(args))
            {
                using (var qmlEngine = new QQmlApplicationEngine())
                {
                    
                    Qml.Net.Qml.RegisterType<Configuracion>("Actualizador");
                    Qml.Net.Qml.RegisterType<CopiaDLLs>("Actualizador");
                    Qml.Net.Qml.RegisterType<CopiaWeb>("Actualizador");
                    Qml.Net.Qml.RegisterType<QBI>("Actualizador");
                    Qml.Net.Qml.RegisterType<BDUpdate>("Actualizador");
                    Qml.Net.Qml.RegisterType<Descarga>("Actualizador");
                    Qml.Net.Qml.RegisterType<Main>("Actualizador");
                    Qml.Net.Qml.RegisterType<Console>("Actualizador");
                    Qml.Net.QApplication app = new QApplication();
                        
                    qmlEngine.Load("Main.qml");
                    
                    
                    return application.Exec();
                }
            }
            }
            else
            {
                Main mMain = new Main();
                mMain.ProcesoCompleto();
                return 0;
            }
        }
    }
}

.csproj

<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>netcoreapp3.1</TargetFramework>
  </PropertyGroup>

  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
    <OutputPath>..\..\Servicio\Wizards\Actualizador\</OutputPath>
  </PropertyGroup>

  <ItemGroup Condition="'$(Configuration)' == 'Debug'">
    <None Update="Main.qml" CopyToOutputDirectory="PreserveNewest" />
    <None Update="pages/**" CopyToOutputDirectory="PreserveNewest" />
    <None Update="images/**" CopyToOutputDirectory="PreserveNewest" />
  </ItemGroup>

  <ItemGroup>
    <PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
    <PackageReference Include="Qml.Net" Version="0.11.0" />
    <PackageReference Include="Qml.Net.LinuxBinaries" Version="0.11.0" />
    <PackageReference Include="Qml.Net.OSXBinaries" Version="0.11.0" />
    <PackageReference Include="Qml.Net.WindowsBinaries" Version="0.11.0" />
    <PackageReference Include="System.Data.SqlClient" Version="4.8.2" />
    <PackageReference Include="System.ServiceProcess.ServiceController" Version="4.7.0" />
  </ItemGroup>


</Project>

and finally attached modules

Modulos

Originally created by @lilongueti on GitHub (Aug 26, 2020). Original GitHub issue: https://github.com/qmlnet/qmlnet/issues/222 the files it need seem to have downloaded properly on C:\users\Administrador\.qmlnet-qt-runtimes based on #173 i'm including the info i guess you'll be asking for here's enviroment variables ``` USERNAME: Administrador PROCESSOR_LEVEL: 6 LOGONSERVER: \\SERVIDORAD HOMEPATH: \Users\Administrador.MONTANA PATHEXT: .COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC ProgramData: C:\ProgramData HOMEDRIVE: C: ProgramFiles: C:\Program Files TEMP: C:\Users\ADMINI~1.MON\AppData\Local\Temp\1 USERDNSDOMAIN: MONTANA.LOCAL PROCESSOR_REVISION: 3f00 ProgramW6432: C:\Program Files SystemDrive: C: CommonProgramW6432: C:\Program Files\Common Files PROCESSOR_ARCHITECTURE: AMD64 Path: C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System3 2\WindowsPowerShell\v1.0\;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\ Binn\;c:\Program Files\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files\Mic rosoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\150\ DTS\Binn\;C:\Program Files\Symantec.cloud\PlatformAgent\;C:\Program Files (x86)\ Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files (x86)\ Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\dotnet\ PSModulePath: C:\Windows\system32\WindowsPowerShell\v1.0\Modules\ CommonProgramFiles: C:\Program Files\Common Files ALLUSERSPROFILE: C:\ProgramData ComSpec: C:\Windows\system32\cmd.exe ProgramFiles(x86): C:\Program Files (x86) USERDOMAIN_ROAMINGPROFILE: MONTANA USERPROFILE: C:\Users\Administrador.MONTANA SESSIONNAME: RDP-Tcp#24 CLIENTNAME: YSERA USERDOMAIN: MONTANA FP_NO_HOST_CHECK: NO CommonProgramFiles(x86): C:\Program Files (x86)\Common Files COMPUTERNAME: SERVERSUMMA windir: C:\Windows NUMBER_OF_PROCESSORS: 4 PROCESSOR_IDENTIFIER: Intel64 Family 6 Model 63 Stepping 0, GenuineIntel APPDATA: C:\Users\Administrador.MONTANA\AppData\Roaming LOCALAPPDATA: C:\Users\Administrador.MONTANA\AppData\Local TMP: C:\Users\ADMINI~1.MON\AppData\Local\Temp\1 SystemRoot: C:\Windows PUBLIC: C:\Users\Public OS: Windows_NT ``` Program.cs ``` using System; using System.IO; using Qml.Net; using Qml.Net.Runtimes; namespace ActualizadorAdvanced { class Program { static int Main(string[] args) { foreach(System.Collections.DictionaryEntry Variable in Environment.GetEnvironmentVariables()) { System.Console.WriteLine(Variable.Key.ToString()+ ": " +Variable.Value); } RuntimeManager.DiscoverOrDownloadSuitableQtRuntime(); System.Console.Read(); if(args.Length==0) { QQuickStyle.SetStyle("Material"); using (var application = new QGuiApplication(args)) { using (var qmlEngine = new QQmlApplicationEngine()) { Qml.Net.Qml.RegisterType<Configuracion>("Actualizador"); Qml.Net.Qml.RegisterType<CopiaDLLs>("Actualizador"); Qml.Net.Qml.RegisterType<CopiaWeb>("Actualizador"); Qml.Net.Qml.RegisterType<QBI>("Actualizador"); Qml.Net.Qml.RegisterType<BDUpdate>("Actualizador"); Qml.Net.Qml.RegisterType<Descarga>("Actualizador"); Qml.Net.Qml.RegisterType<Main>("Actualizador"); Qml.Net.Qml.RegisterType<Console>("Actualizador"); Qml.Net.QApplication app = new QApplication(); qmlEngine.Load("Main.qml"); return application.Exec(); } } } else { Main mMain = new Main(); mMain.ProcesoCompleto(); return 0; } } } } ``` .csproj ``` <Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <OutputType>Exe</OutputType> <TargetFramework>netcoreapp3.1</TargetFramework> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> <OutputPath>..\..\Servicio\Wizards\Actualizador\</OutputPath> </PropertyGroup> <ItemGroup Condition="'$(Configuration)' == 'Debug'"> <None Update="Main.qml" CopyToOutputDirectory="PreserveNewest" /> <None Update="pages/**" CopyToOutputDirectory="PreserveNewest" /> <None Update="images/**" CopyToOutputDirectory="PreserveNewest" /> </ItemGroup> <ItemGroup> <PackageReference Include="Newtonsoft.Json" Version="12.0.3" /> <PackageReference Include="Qml.Net" Version="0.11.0" /> <PackageReference Include="Qml.Net.LinuxBinaries" Version="0.11.0" /> <PackageReference Include="Qml.Net.OSXBinaries" Version="0.11.0" /> <PackageReference Include="Qml.Net.WindowsBinaries" Version="0.11.0" /> <PackageReference Include="System.Data.SqlClient" Version="4.8.2" /> <PackageReference Include="System.ServiceProcess.ServiceController" Version="4.7.0" /> </ItemGroup> </Project> ``` and finally attached modules ![Modulos](https://user-images.githubusercontent.com/52230217/91255294-19759380-e72a-11ea-9783-11614102b1d8.png)
Author
Owner

@pauldotknopf commented on GitHub (Aug 26, 2020):

Can you use depends.exe on QmlNet.dll and make sure you have the proper VC++ runtime?

Also, can you share a repo to reproduce?

<!-- gh-comment-id:680870436 --> @pauldotknopf commented on GitHub (Aug 26, 2020): Can you use ```depends.exe``` on ```QmlNet.dll``` and make sure you have the proper VC++ runtime? Also, can you share a repo to reproduce?
Author
Owner

@lilongueti commented on GitHub (Aug 26, 2020):

didn't realize i'd need vc++, it worked perfectly after installing it, thanks

<!-- gh-comment-id:681152139 --> @lilongueti commented on GitHub (Aug 26, 2020): didn't realize i'd need vc++, it worked perfectly after installing it, thanks
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/qmlnet#142
No description provided.