Pastebin
Retrouvez, créez et partagez vos snippets en temps réel.
Rechercher un Pastebin
Aucun paste trouvé.
Créer un paste
Pastebin
Blog
test
# --- Variables des URLs --- $urls = @( "https://news.google.com", # Écran 1 - News "https://weather.com", # Écran 2 - Météo "http://IP_DE_TES_CAMERAS", # Écran 3 - Caméras "https://www.tradingview.com" # Écran 4 - Bourse ) # --- Dimensions des écrans --- $screenWidth = 2560 $screenHeight = 1440 # --- Lancer Edge en mode kiosque pour chaque URL --- for ($i=0; $i -lt $urls.Count; $i++) { Start-Process "msedge.exe" "--kiosk $($urls[$i]) --edge-kiosk-type=fullscreen" Start-Sleep -Seconds 5 # Attendre que la fenêtre se lance # --- Déplacer la fenêtre sur le bon écran --- # Récupérer la fenêtre Edge $hwnd = (Get-Process msedge | Select-Object -Last 1).MainWindowHandle # Calculer la position horizontale selon l'écran $x = $i * $screenWidth $y = 0 # Déplacer la fenêtre Add-Type @" using System; using System.Runtime.InteropServices; public class WinAPI { [DllImport("user32.dll")] public static extern bool MoveWindow(IntPtr hWnd, int X, int Y, int nWidth, int nHeight, bool bRepaint); } "@ [WinAPI]::MoveWindow($hwnd, $x, $y, $screenWidth, $screenHeight, $true) } Write-Host "Mur d'écrans initialisé !"
Créé il y a 2 semaines.