Jump to content

C# Ile Başlığı Split Mode Ile Textbox'lara Yazma?


shalyangose
 Share

Recommended Posts

Merhabalar,

C# ile kısa süredir haşırneşirim. Ufak tefek işlerimi yapabiliyorum. Şimdi elimdeki film arşivini bir database üzerinde tutmak istiyorum. Bunun için elimde filmlerin isimlerinin listesi .txt formatında aldım.  Etiket listesi aşağıdaki gibi.

Collateral [2004 - 720p - BluRay - 5.1CH - x264 - Dual]
Contact [1997 - 720p - BluRay - DTS - x264 - Dual]
Crazy Heart [2009 - 720p - BluRay - 5.1CH - x264 - Dual]

Şimdi yapmak istediğim liste olan txt dosyasını listboxa aktarıp, listbox üzerinden film başlığı tıklandığında Film adını bir text box'a , çıkış yılını bir textbox'a Bluray olduğunu ayrı bir textbox'a ve Dual olduğunu diğer bir text'a yazdırmak istiyorum.

Bunu split yöntemi ile yapmak istedim fakat bir türlü sonuca ulaşamadım. Bu şekilde yada alternatif olarak nasıl bir yol izlemeliyim?

Yardımlarınızı rica ederim. Şimdiden teşekkürler.

Link to comment
Share on other sites

C# yüklü değil online compiler ile şöyle bişey oluşturdum. Bunu bi class a dökersen temiz bir kod olur.

 

string islem = "Collateral [2004 - 720p - BluRay - 5.1CH - x264 - Dual]";
            Match match = Regex.Match(islem,@"^(.*) \[([0-9]{4}) - (.*) - (.*) - (.*) - (.*) - (.*)\]");
            string name = match.Groups[1].Value;
            string year = match.Groups[2].Value;
            string screen = match.Groups[3].Value;
            string type = match.Groups[4].Value;
            string channel = match.Groups[5].Value;
            string rip = match.Groups[6].Value;
            string audio = match.Groups[7].Value;

Link to comment
Share on other sites

Harikasın @Extended Hocam, tamda araştırmalarım sonucu harmanladığım bilgiler ile bende bişiler elde ettim diye girdim konuya cevabını gördüm bana ek bir bilgi oldu :D

Bende bu şekilde bir çözüm buldum. Aradaki boşluklarıda sıfırladım. ve listbox'ın ilk item'ini selected yaptım :D Umarım başkalarınında işine yarar. Yardımlarınız için teşekkür ederim.

        private void btn_cevir_Click(object sender, EventArgs e)
        {
            string[] olusan = listBox1.Text.Split('[','-',']');
            if (olusan[1].Length > 0)
            {
                txt_filmadi.Text = olusan[0];
                txt_filmyili.Text = olusan[1];
                txt_cozunurluk.Text = olusan[2];
                txt_format.Text = olusan[3];
                txt_seskanali.Text = olusan[4];
                txt_codec.Text = olusan[5];
                txt_dilsecenegi.Text = olusan[6];

                txt_filmyili.Text = txt_filmyili.Text.Replace(" ", "");
                txt_cozunurluk.Text = txt_cozunurluk.Text.Replace(" ", "");
                txt_format.Text = txt_format.Text.Replace(" ", "");
                txt_seskanali.Text = txt_seskanali.Text.Replace(" ", "");
                txt_codec.Text = txt_codec.Text.Replace(" ", "");
                txt_dilsecenegi.Text = txt_dilsecenegi.Text.Replace(" ", "");

                while (listBox1.SelectedItems.Count > 0)
                {
                    listBox1.Items.Remove(listBox1.SelectedItems[0]);
                }
            }
        }

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Similar Content

    • By artae
      File size: 1.82 / 3.67 MB

      Split PDF file into multiple parts, extract specific pages from PDF file, and combine two or merge more PDF files into one.

      Whats New
      Updates: official site does not provide any info about changes in this version

      HOMEPAGE
      https://www.bureausoft.com/

      PDF Split & Merge Pro 7.0

      PDF Split & Merge Pro 7.0 Portable
      DOWNLOAD
      (Buy premium account for maximum speed and resuming ability)


      https://nitroflare.com/view/D599320C6EA338A/13qrp..BureausoftPDFSplitMergePro7.0.rar
      https://nitroflare.com/view/5A12F348EFD025F/13qrp..BureausoftPDFSplitMergePro7.0Portable.rar



      https://rapidgator.net/file/3dacd346052f23c98710dedfc0eec26e/13qrp..BureausoftPDFSplitMergePro7.0.rar
      https://rapidgator.net/file/3cbcfd60d136144718c902ab4c90f171/13qrp..BureausoftPDFSplitMergePro7.0Portable.rar


    • By artae
      WekApps PDF Merge & Split Pro 1.22 Multilingual Portable
      File size: 15 MB

      Merge and split PDF files easily with Wek PDF Merge & Split Pro. You can split PDF into single-page files, split by page ranges, split by bookmark level. You can also merge PDF files into a single document easily. You can also easily preview the content of the PDF page you want to process. Work with password-protected files and set your own file permissions and metadata.

      Multiple, clear options for both splitting and merging PDF files, which enhance handling and processing efficiency
      Users will be able to load their files easily, either by using the provided directory navigation input, or, by simply dragging and dropping the files directly onto the interface. This reduces the processing time right from the start.

      Furthermore, simplicity and efficiency are also emphasized through the clear, intelligible options concerning both splitting and merging. Easy tick selectors make for a quick process, and simple numerical inputs using drop-down menus complete the intuitive handling. A breeze, even for novices, or those who tend to avoid complicated solutions.

      Minimalist, easy-to-set options, which don't get in the way when wanting to focus on the processing itself
      The simplicity of the approach is also maintained throughout the entirety of the application, including its settings module. Here, one will be able to rely on just three tabs for controlling the behavior and characteristics of the app.

      We believe that the provided options are sufficient for the scope of the app, and manage to allow tweaks for the essential characteristics of the documents, without being limited.

      No-hassle PDF handler, which offers both splitting and merging, in an accessible, down-to-earth package
      If you seek a tool that can help you either split or merge PDF documents, without having to go through some complex procedures, then this application might just be the right choice for you.
      DOWNLOAD
      (Buy premium account for maximum speed and resuming ability)


      https://nitroflare.com/view/EB9B7CDFF0BB6C5/er1zs.WekApps.PDF.Merge..Split.Pro.1.22.Multilingual.Portable.rar



      https://rapidgator.net/file/53eab363bcc5920e3486129291e3aa03/er1zs.WekApps.PDF.Merge..Split.Pro.1.22.Multilingual.Portable.rar


    • By artae
      SysTools Split PST 8.0 (x64)
      Languages: English | File size: 18.5 MB

      Looking for a solution to Split Outlook PST file into smaller parts with complete data? Use Microsoft PST splitter tool to divide Outlook data file and open large PST file instantly. This tool offers 4 unique option to partition PST file i.e., by size, date, year, folder. This software also supports to truncate corrupted or damaged Outlook mailbox items containing emails, contacts, calendars, notes, journals without any file size limitation.

      Main Features:
      - Split large PST file into smaller parts by size, date, year, & folder
      - Give freedom to split Outlook archive PST file or active PST file
      - The software permits to split corrupted PST file due to large size
      - Easily cut Outlook data file with all emails, contacts, calendars, notes, etc.
      - Facilitates option to split Outlook contacts & calendars by date
      - Option to split one PST to multiple files by size 5 MB to 45 GB as per the need
      - Split oversized PST file by folder & create specific file for each folder
      - The tool supports to divide both ANSI PST and UNICODE PST file
      - Provides option of Exclude Deleted Items while splitting PST file
      - Works with all Outlook versions like Outlook 2019, 2016, 2013, 2010, 2007, etc.
      - Compatible with Windows 10, 8.1, 8, 7, and all below versions
      - MS Outlook installation is required to divide large PST file into smaller files

      Split Large PST File
      MS Outlook PST file splitter allows you to divide large PST file of any size into smaller files. It is possible to divide UNICODE as well as ANSI PST files without losing any data. Also, the tool keeps meta properties and formatting of each item, intact. The software also provides option to "Exclude Deleted Items" while splitting up large PST File.

      Divide PST File by Date
      MS Outlook PST file splitter allows you to break up PST file by date. Here you can select a specific date and software will split Outlook archive PST file by date in two parts. One part of PST file will contain the data 'of and prior' to the specified date while other part will have the data 'after' that date. It will also allow to split Outlook contacts & calendars by date.

      Cut PST File by Size
      With the help of this option, you can easily split Outlook PST file into smaller parts; using a common size for all. Define the PST file size range from 5 MB to 45 GB (46080 MB) and the Outlook PST break tool will accordingly split one PST to multiple files. It has the ability to split unlimited PST files without losing individual information.

      Truncate PST File by Year
      If you want to divide Outlook data file by year, then split by year option will prove helpful to split large Outlook PST into smaller files yearly. The PST divider lets you to create multiple PST files for each year, for example: if you selected year from 2010 to 2014 then you will get 5 PST files separately. Also, you can crop PST file by current year 2014 and upcoming year i.e. 2015.

      Separate PST File by Folder
      In this option, you can create multiple PST files for each folder by size. Best PST file splitter software will create separate PST file for each folder present within the Outlook PST file and further divide the respective folder by size specified by you. Like: Inbox.pst for inbox folder, Outlook.pst for Outbox folder, contacts.pst for contacts folder and so on.

      Split Outlook Archive Files
      The split large PST file freeware also allows to split Outlook archive file/folder. It provides option to split Outlook PST archive file by date, by size, by year or by folder which could be managed easily after importing it in Outlook.

      Oversized PST File Corruption Issue
      Outlook PST file splitter tool has the capability to split oversized PST file that are already corrupted due to oversizing. Although, you can split one PST to multiple files of size closer or more than 2 GB; in case of ANSI PST file formats. The software can easily divide PST file corrupted due to large size or any other issue.

      Log Report to Compare PST File
      After the completion of splitting up PST into smaller files, software generates & saves a complete comparison report as CSV. This report includes fields like: Folder name, Folder path, Number of items in source PST files each folder, sum and difference of items before and after PST file splitting.

      Make New Folder to Save PST
      It is possible to save Outlook data file after splitting; to any location of your choice. Also, if required, create a new folder directly from the Outlook PST Split software panel and save the files into it. Also, the CSV file report will get saved at similar location; by default.

      Option to Choose Outlook Format
      While choosing a splitting option, you also need to select the MS Outlook format you are using. The split oversized PST file tool supports Outlook 2019, 2016, 2013, 2010, 2007, and other Outlook versions. Thus, if you specify the Outlook version, the software will automatically detect the format of PST file and easily split PST file into smaller parts.

      Support Corrupted or Inaccessible PST File
      There are multiple reasons due to which Outlook PST file gets corrupted such as hardware issues, virus issues, abnormal shutdown, large size of PST file. The split large PST file freeware supports to divide such corrupted or damaged PST file into smaller files without any complications.

      RELEASE NOTES:
      - Release notes were unavailable when this listing was updated.

      System Requirements:
      - Windows 2000, 2003, 2008, XP, Vista, Windows 7/8/8.1, 2008/2012 , Windows 10 (32-bit & 64-bit)
      - If you are using Windows 10/8.1/8/7 or Vista, then please launch the tool as "Run as Administrator"
      - MS Outlook - 2000, 2003, 2007, 2010(32/64 bit), 2013 (32/64 bit), 2016 (32/64 bit)
      - Microsoft .NET framework 4.0
      DOWNLOAD
      (Buy premium account for maximum speed and resuming ability)


      https://nitroflare.com/view/1E0A11174BB0CD6/enppr.SysTools.Split.PST.8.0.x64.rar



      https://rapidgator.net/file/34988caf43a8705830a95339497924b9/enppr.SysTools.Split.PST.8.0.x64.rar


  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...