نمایش نتایج 1 تا 2 از 2

نام تاپیک: بریدن متن از قسمتی به بعد و به قبل ؟

  1. #1

    بریدن متن از قسمتی به بعد و به قبل ؟

    با سلام
    دوستان چطور میشه یک متن رو داخل نرم افزارمون از قسمتی به قبل و از قسمتی به بعد برید ؟

    برای مثال این متن ماست :



    An Arizona black history professor has been caught repeatedly plagiarizing material for textbooks, including by copying paragraphs from sites like Wikipedia. Despite this, he has been punished with a relative slap on the wrist, keeping his job and losing only a small part of his generous salary.
    Until the last few days, Matthew Whitaker was a full professor at Arizona State University and was the founding director of the school’s Center for the Study of Race and Democracy. But complaints from Whitaker’s fellow academics and an anonymous blog forced the school to investigate one of his textbooks, “Peace Be Still: Modern Black America From World War II to Barack Obama”. The investigation discovered “significant issues” with the book, such as major passages ripped from other books or even websites like Infoplease.

    The website Inside Higher Ed compared passages in Whitaker’s book to uncited outside sources when the new accusations first surfaced is 2014. For example, this is a passage from the website Infoplease

    حالا من میخواهم این متن از کلمات keeping his job and به بعد و از کلمات uncited outside sources به قبل رو ببرم و از متن بالا این متن باقی بمونه ؟

    losing only a small part of his generous salary
    Until the last few days, Matthew Whitaker was a full professor at Arizona State University and was the founding director of the school’s Center for the Study of Race and Democracy. But complaints from Whitaker’s fellow academics and an anonymous blog forced the school to investigate one of his textbooks, “Peace Be Still: Modern Black America From World War II to Barack Obama”. The investigation discovered “significant issues” with the book, such as major passages ripped from other books or even websites like Infoplease.

    The website Inside Higher Ed compared passages in Whitaker’s book to


    ممنون میشم راهنمایی کنید ...

  2. #2

    نقل قول: بریدن متن از قسمتی به بعد و به قبل ؟

    سلام خیلی آسونه!

    string source = "matnet";string startRemove = "keeping his job and";
    string endRemove = "uncited outside sources";


    string str = source.Substring(source.IndexOf(startRemove));
    str = str.Substring(0,str.IndexOf(endRemove));



    حالا اگه میخوای
    keeping his job and
    هم داخلش نباشه کافیه که کد زیر رو:
    string str = source.Substring(source.IndexOf(startRemove));

    اینطوری بنویسی:
    string str = source.Substring(source.IndexOf(startRemove) + startRemove.Length);




    اگه میخوای توی متنت
    uncited outside sources
    هم باشه، کافیه کد زیر رو:
    str = str.Substring(0,str.IndexOf(endRemove));

    این شکلی بنویسی:
    str = str.Substring(0,str.IndexOf(endRemove) + endRemove.Length);


    اگه کلمه ای رو اشتباه نوشتم ببخشید، چون از حفظ نوشته شده.
    موفق باشید

تاپیک های مشابه

  1. بریدن متن همراه با کدهای html
    نوشته شده توسط erfannorouzi در بخش PHP
    پاسخ: 3
    آخرین پست: سه شنبه 07 بهمن 1393, 03:03 صبح
  2. مبتدی: پاک شدن متن داخل تکست باکس بعد از ارسال فرم و یا refresh
    نوشته شده توسط samira_66 در بخش طراحی وب (Web Design)
    پاسخ: 4
    آخرین پست: دوشنبه 29 اردیبهشت 1393, 07:38 صبح
  3. جدا کردن متن یک تکس باکس بعد از یک فاصله خالی
    نوشته شده توسط patrick5053 در بخش C#‎‎
    پاسخ: 6
    آخرین پست: پنج شنبه 15 اسفند 1392, 22:38 عصر
  4. شکستن متن label به خط بعد
    نوشته شده توسط BestFriend در بخش ASP.NET Web Forms
    پاسخ: 19
    آخرین پست: دوشنبه 28 بهمن 1392, 11:46 صبح
  5. سوال: نوشتن متن در TextBox خاص بعد از Add شدن در حین اجرای برنامه
    نوشته شده توسط saeid.71 در بخش C#‎‎
    پاسخ: 7
    آخرین پست: چهارشنبه 30 فروردین 1391, 09:54 صبح

قوانین ایجاد تاپیک در تالار

  • شما نمی توانید تاپیک جدید ایجاد کنید
  • شما نمی توانید به تاپیک ها پاسخ دهید
  • شما نمی توانید ضمیمه ارسال کنید
  • شما نمی توانید پاسخ هایتان را ویرایش کنید
  •