Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Quand tu ouvre quelle texte en winrar ??Merci pour le partage ! mais le problème c'est que quand j'ouvre le texte winrar bugJe pense que sa vient de chez moi mais esque sa fait sa a quelqu’un d'autre ?
Il marche tres bien la preuve la preuve dans le tutoTon tuto marche pas![]()
Le bon codagenamespace WindowsFormsApplication2
{
public partial class Form1 : XtraForm
{
private readonly string Version = "1.0.0.0";
public void checkForUpdate()
{
string URL = " Votre Site ou ya votre serveur FTP ";
string appNAME = "tool.rar";
string serverVersion;
string serverVersionName = "ToolVersion.txt";
WebRequest req = WebRequest.Create(URL + serverVersionName);
WebResponse res = req.GetResponse();
Stream str = res.GetResponseStream();
StreamReader tr = new StreamReader(str);
serverVersion = tr.ReadLine();
if (getVersion() != serverVersion)
{
DialogResult dialogResult = MessageBox.Show("A New Update is Available \nDo You Want to Download it now ?", "Auto Update Panel", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dialogResult == DialogResult.Yes)
{
WebClient client = new WebClient();
byte[] appdata = client.DownloadData(URL + appNAME);
if (saveFileDialog1.ShowDialog() == DialogResult.OK)
{
using (FileStream fs = File.Create(saveFileDialog1.FileName))
{
fs.Write(appdata, 0, appdata.Length);
}
MessageBox.Show("Download Location " + saveFileDialog1.FileName + " Enjoy The New Features !!", "Auto Update Pannel", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
}
else if (dialogResult == DialogResult.No)
{
// do nothing
}
}
else
{
// do nothing
}
}
Ensuite cree un fichier Txt ou vous metre 1.0.0.0 (quand vous le modifirai par 1.0.0.1 sa uploadera la new MAJ
Ensuite crée un RAR avec votre tool
Et les metre les deux sur votre serveur FTP
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Net;
using System.Diagnostics;
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
string ver = Application.ProductVersion.ToString();
WebClient Client = new WebClient();
string vers = Client.DownloadString("lien/maj.html");
if (ver != vers) {
DialogResult result = MessageBox.Show("Une mise à jours est disponible", "Mise à jours", MessageBoxButtons.YesNo);
if (result == DialogResult.Yes)
{
Client.DownloadProgressChanged += tele_ProgressChanged;
Client.DownloadFileCompleted += tele_DownloadCompleted;
Client.DownloadFileAsync(new Uri("Adresse du update à télécharger"), "Nom du update à télécharger.exe");
}
else if (result == DialogResult.No)
{
MessageBox.Show("Certaine fonction du logiciel risque d'être plus fonctionnel");
}
}
}
private void tele_ProgressChanged(object sender, DownloadProgressChangedEventArgs e)
{
double bytesIn = double.Parse(e.BytesReceived.ToString());
double totalBytes = double.Parse(e.TotalBytesToReceive.ToString());
double percentage = bytesIn / totalBytes * 100;
progressBar1.Value = Int32.Parse(Math.Truncate(percentage).ToString());
}
private void tele_DownloadCompleted(object sender, System.ComponentModel.AsyncCompletedEventArgs e)
{
Process.Start("nom du update.exe");
this.Close();
}
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Net;
using System.Diagnostics;
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
WebClient Client = new WebClient();
Client.DownloadProgressChanged += tele_ProgressChanged;
Client.DownloadFileCompleted += tele_DownloadCompleted;
Client.DownloadFileAsync(new Uri("Adresse du logiciel à télécharger"), "Nom du logiciel à télécharger.exe");
}
private void tele_ProgressChanged(object sender, DownloadProgressChangedEventArgs e)
{
double bytesIn = double.Parse(e.BytesReceived.ToString());
double totalBytes = double.Parse(e.TotalBytesToReceive.ToString());
double percentage = bytesIn / totalBytes * 100;
progressBar1.Value = Int32.Parse(Math.Truncate(percentage).ToString());
}
private void tele_DownloadCompleted(object sender, System.ComponentModel.AsyncCompletedEventArgs e)
{
Process.Start("nom du logiciel.exe");
this.Close();
}
}
}
La vidéo est morte !Helloo
Je vous présente mon tuto en vidéo car il est long et sa sera peut être plus simple a comprendre.
Je vous laisse a vidéo et bonne chance
Vous devez être inscrit pour voir les médias
Tchiaoooo
Helloo
Je vous présente mon tuto en vidéo car il est long et sa sera peut être plus simple a comprendre.
Je vous laisse a vidéo et bonne chance
Vous devez être inscrit pour voir les médias
Tchiaoooo
vidéo hsHelloo
Je vous présente mon tuto en vidéo car il est long et sa sera peut être plus simple a comprendre.
Je vous laisse a vidéo et bonne chance
Vous devez être inscrit pour voir les médias
Tchiaoooo