No cache version.

Caching disabled. Default setting for this page:enabled (code LNG204)
If the display is too slow, you can disable the user mode to view the cached version.

WebInfoControl.cs

Description du code

WebInfoControl.cs est un fichier du projet BiblioBrol.
Ce fichier est situé dans /var/www/bin/sniplets/bibliobrol/src/.

Projet BiblioBrol :

Gestion de media en CSharp.

Pour plus d'infos, vous pouvez consulter la brève analyse.

Code source ou contenu du fichier

  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Drawing;
  5. using System.Data;
  6. using System.Text;
  7. using System.Windows.Forms;
  8. using be.gaudry.model;
  9.  
  10. namespace be.gaudry.bibliobrol.view.controls.webInfo
  11. {
  12. public partial class WebInfoControl : UserControl
  13. {
  14. private String uriFormat;
  15. private bool uriEncodeParam;
  16. public WebInfoControl()
  17. {
  18. InitializeComponent();
  19. }
  20.  
  21. public String UriFormat
  22. {
  23. get { return this.uriFormat; }
  24. set { this.uriFormat = value; }
  25. }
  26.  
  27. public bool UriEncodeParam
  28. {
  29. get { return this.uriEncodeParam; }
  30. set { this.uriEncodeParam = value; }
  31. }
  32.  
  33. public void setUriParam (String param)
  34. {
  35. queryTB.Text = param.ToLowerInvariant();
  36. }
  37.  
  38.  
  39. private void goBtn_Click(object sender, EventArgs e)
  40. {
  41. String url = String.Format(uriFormat,
  42. (uriEncodeParam) ? Uri.EscapeDataString(queryTB.Text) : queryTB.Text);
  43. if (checkUrl(url))
  44. webBrowser.Navigate(url);
  45. }
  46. private void showWebBrowser(bool show, String text)
  47. {
  48. infoLbl.Text = text;
  49. webPanel.Visible = show;
  50. infoLbl.Visible = !show;
  51. }
  52. private bool checkUrl(String url)
  53. {
  54. if (!WebHelper.isConnected())
  55. {
  56. showWebBrowser(false,"Impossible de se connecter à Internet.");
  57. return false;
  58. }
  59. if (String.Empty.Equals(url))
  60. {
  61. showWebBrowser(false,"");
  62. return false;
  63. }
  64. if (!WebHelper.testUrl(url))
  65. {
  66. showWebBrowser(false, "Impossible de charger le document demandé.");
  67. return false;
  68. }
  69. showWebBrowser(true, "");
  70. return true;
  71. }
  72.  
  73. private void queryTB_KeyPress(object sender, KeyPressEventArgs e)
  74. {
  75. if (e.KeyChar == (char)Keys.Return)
  76. {
  77. e.Handled = true;
  78. goBtn_Click(sender, new EventArgs());
  79. }
  80. }
  81. }
  82.  
  83.  
  84. }

Structure et Fichiers du projet

Afficher/masquer...


Répertoires contenus dans /var/www/bin/sniplets/bibliobrol/src/view/controls/webInfo/ 
IcôneNomTailleModification
Pas de sous-répertoires.
IcôneNomTailleModification
| _ Répertoire parent0 octets1717236238 01/06/2024 12:03:58
Fichiers contenus dans /var/www/bin/sniplets/bibliobrol/src/view/controls/webInfo/ 
IcôneNomTailleModificationAction
IcôneNomTailleModificationAction
Afficher le fichier .cs|.csWebInfoBDControl.cs1.22 Ko31/10/2018 18:33:20-refusé-
Afficher le fichier .cs|.csIWebInfo.cs493 octets31/10/2018 18:33:20-refusé-
Afficher le fichier .cs|.csWebInfoBDControl.Designer.cs9.51 Ko31/10/2018 18:33:20-refusé-
Afficher le fichier .resx|.resxWebInfoBDControl.resx5.68 Ko31/10/2018 18:33:20-refusé-
Afficher le fichier .cs|.csWebInfoFilmsControl.cs1.28 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .resx|.resxWebInfoControl.resx5.68 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .cs|.csWebInfoFilmsControl.Designer.cs9.72 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .cs|.csWebInfoDefaultControl.Designer.cs5.45 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .cs|.csWebInfoControl.cs2.29 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .cs|.csWebInfoDefaultControl.cs1.21 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .resx|.resxWebInfoDefaultControl.resx6.04 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .resx|.resxWebInfoFilmsControl.resx5.68 Ko31/10/2018 18:33:21-refusé-
Afficher le fichier .cs|.csWebInfoControl.Designer.cs7.72 Ko31/10/2018 18:33:21-refusé-

Utilisation de l'explorateur de code

  • Navigation :
    • Un clic sur une icône de répertoire ouvre ce répertoire pour en afficher les fichiers.
    • Lorsque le répertoire en cours ne contient pas de sous-répertoires il est possible de remonter vers le répertoire parent.
    • La structure de répertoires en treetable (tableau en forme d'arborescence) n'est plus possibledans cette version.
    • Un clic sur une icône de fichier ouvre ce fichier pour en afficher le code avec la coloration syntaxique adaptée en fonction du langage principal utilisé dans le fichier.
  • Affichage :
    • Il est possible de trier les répertoires ou les fichiers selon certains critères (nom, taille, date).
  • Actions :
    • Les actions possible sur les fichiers dépendent de vos droits d'utilisateur sur le site. Veuillez activer le mode utilisateur pour activer les actions.

English translation

You have asked to visit this site in English. For now, only the interface is translated, but not all the content yet.

If you want to help me in translations, your contribution is welcome. All you need to do is register on the site, and send me a message asking me to add you to the group of translators, which will give you the opportunity to translate the pages you want. A link at the bottom of each translated page indicates that you are the translator, and has a link to your profile.

Thank you in advance.

Document created the 16/10/2009, last modified the 26/10/2018
Source of the printed document:https://www.gaudry.be/en/cs-bibliobrol-source-rf-view/controls/webInfo/WebInfoControl.cs.html

The infobrol is a personal site whose content is my sole responsibility. The text is available under CreativeCommons license (BY-NC-SA). More info on the terms of use and the author.