Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
R

rockram

@rockram
About
Posts
9
Topics
6
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Error:server.mappath
    R rockram

    code: private void LoadDictArray(string strPath, string strBegin) { bool boolStart = false; string strCurrent = ""; string strFinal = ""; string filepath = "C:/Documents and Settings/Owner/My Documents/Visual Studio 2005/sample/dict-large.txt"; // Open our dictionary file StreamReader srDictionary = new StreamReader(Server.MapPath("filepath"));--->Error Line // Check each line and loop while there is another while (srDictionary.Peek() != -1) { // Read the current line strCurrent = srDictionary.ReadLine(); // Does the first character match our word's if (strCurrent.Substring(1).ToLower() == strBegin.ToLower()) { boolStart =true; // Only add words beginning with the same letter as the current word strFinal += strCurrent; } // Exit, we have all our relevant words if (boolStart == true & strCurrent.Substring(1).ToLower() != strBegin.ToLower()) { break; // TODO: might not be correct. Was : Exit While } } // Close the streamreader srDictionary.Close(); char[] char1 ={ '\n' }; // Split our string into an array of suitable words strDictArray =strFinal.Split(char1); } The dict-large.txt file is in the solution explorer itself

    ASP.NET csharp visual-studio sysadmin data-structures regex

  • Error:server.mappath
    R rockram

    private void LoadDictArray(string strPath, string strBegin) { bool boolStart = false; string strCurrent = ""; string strFinal = ""; string filepath = "C:/Documents and Settings/Owner/My Documents/Visual Studio 2005/sample/dict-large.txt"; // Open our dictionary file StreamReader srDictionary = new StreamReader(Server.MapPath("dict-large.txt"));--->Error Line // Check each line and loop while there is another while (srDictionary.Peek() != -1) { // Read the current line strCurrent = srDictionary.ReadLine(); // Does the first character match our word's if (strCurrent.Substring(1).ToLower() == strBegin.ToLower()) { boolStart =true; // Only add words beginning with the same letter as the current word strFinal += strCurrent; } // Exit, we have all our relevant words if (boolStart == true & strCurrent.Substring(1).ToLower() != strBegin.ToLower()) { break; // TODO: might not be correct. Was : Exit While } } // Close the streamreader srDictionary.Close(); char[] char1 ={ '\n' }; // Split our string into an array of suitable words strDictArray =strFinal.Split(char1); }

    ASP.NET csharp visual-studio sysadmin data-structures regex

  • Error:Cannot convert type string to int
    R rockram

    Hello sir Thanks for your reply Here is my code: using System; using System.IO; using System.Web.UI.WebControls.WebParts; using System.Web.UI.HtmlControls; partial class SpellSuggest : System.Web.UI.Page { private string[] strDictArray; private bool boolDictionaryLoaded = false; private int intErrors = 0; protected void Page_Load(object sender, System.EventArgs e) { int iCurrentCount = 0; string[] arrWords; string strCompleteOriginal = ""; int iWordCount = 0; //string hfOriginalString.Value, hfCurrentCount.Value, hfErrors.Value, hfWordCount.Value; char[] chSplit ={ ' ' }; //string strAlternative = ""; int i = 0; string strText; strText = Request.QueryString["txtContent"]; strText = strText.Trim(); // If nothing to check, exit the procedure if (strText == "") { return; // TODO: might not be correct. Was : Exit Sub } else { // Get the string to check strCompleteOriginal = strText; } // First time the page is loaded if (!IsPostBack) { // Initialize current word index to zero iCurrentCount = 0; // Initialize total word count to zero iWordCount = 0; // Initialize total invalid word count to zero intErrors = 0; // Set value of hidden field containing complete original string to check hfOriginalString.Value = strCompleteOriginal; // Set value of hidden field containing current index hfCurrentCount.Value = "0"; // Split into an array of individual words arrWords = strCompleteOriginal.Split(chSplit); // Count total number of words iWordCount = arrWords.Length; // Set value of hidden field containing total number of words hfWordCount.Value = Convert.ToString(iWordCount); // Set value of hidden field containing total number of invalid words hfErrors.Value = "0"; } else { // Not the first time, split hidden field into an array of individual words arrWords = hfOriginalString.Value.Split(chSplit); // Get index for current word in the array iCurrentCount = Convert.ToInt32(hfCurrentCount.Value); // Get current number of

    ASP.NET help

  • Error:Cannot convert type string to int
    R rockram

    Code: foreach(int strAlternative in Suggest(arrWords[iCurrentCount]))-->Error Line { lbSuggestions.Items.Add(new ListItem(strAlternative, strAlternative)); }

    ASP.NET help

  • Error:Type and identifier are both required in a foreach statement
    R rockram

    Code: foreach ( strSuggestion in functionReturnValue) { dblSimilarity = WordSimilarity(strWord, strSuggestion); i = intSuggestionCount; while (dblSimilarity > dblSimilarityArray(i)) { if (i < intSuggestionCount) { strSuggestionArray(i + 1) = strSuggestionArray(i); dblSimilarityArray(i + 1) = dblSimilarityArray(i); } strSuggestionArray(i) = strSuggestion; dblSimilarityArray(i) = dblSimilarity; i = i - 1; if (i == -1) { break; // TODO: might not be correct. Was : Exit Do } } } functionReturnValue = strSuggestionArray; return functionReturnValue; return functionReturnValue; }

    ASP.NET help

  • Error
    R rockram

    My code: foreach ( strSuggestion in functionReturnValue) { dblSimilarity = WordSimilarity(strWord, strSuggestion); i = intSuggestionCount; while (dblSimilarity > dblSimilarityArray(i)) { if (i < intSuggestionCount) { strSuggestionArray(i + 1) = strSuggestionArray(i); dblSimilarityArray(i + 1) = dblSimilarityArray(i); } Error:Type and identifier are both required in a foreach statement

    ASP.NET help

  • SpellCheck Error
    R rockram

    Code: using System; using System.IO; using System.Configuration; using System.Data; using System.Collections; using System.Text; partial class Default2 : System.Web.UI.Page { private string[] strDictArray; private bool boolDictionaryLoaded = false; private int intErrors = 0; protected void Page_Load(object sender, System.EventArgs e) { int iCurrentCount = 0; string[] arrWords; string strCompleteOriginal = ""; int iWordCount = 0; string strAlternative = ""; int i = 0; if (string.Trim(Request.Querystring["txtContent"]) == "") { return; // TODO: might not be correct. Was : Exit Sub } else { strCompleteOriginal = string.Trim(Request.Querystring("txtContent")); } if (!IsPostBack==false) { iCurrentCount = 0; iWordCount = 0; intErrors = 0; hfOriginalstring.Value = strCompleteOriginal; hfCurrentCount.Value = "0"; arrWords = string.Split(strCompleteOriginal, " "); iWordCount = arrWords.Length; hfWordCount.Value = iWordCount; hfErrors.Value = "0"; } else { arrWords = string.Split(hfOriginalstring.Value, " "); iCurrentCount = hfCurrentCount.Value; intErrors = int.Parse(hfErrors.Value); } txtCurrent.Value = arrWords[iCurrentCount]; if (Request.Form["cmdCancel"] == "Stop") { arrWords = string.Split(hfOriginalstring.Value, " "); iWordCount = hfWordCount.Value; string strReplace = hfFinal.Value; int j = 0; for (j = iCurrentCount; j <= iWordCount - 1; j++) { strReplace += arrWords[j] + " "; } intErrors -= 1; stopChecking("frmSpellCheck", "txtContent", strReplace); return; // TODO: might not be correct. Was : Exit Sub } if (Request.Form["cmdNext"] == "Next") { arrWords = string.Split(hfOriginalstring.Value, " "); iWordCount = hfWordCount.Value; if (txtManual.Value == "") { arrWords[iCurrentCount] = lbSuggestions.SelectedValue; hfFinal.Value += lbSuggestions.SelectedValue + " "; } else { arrWords[iCurrentCount]

    ASP.NET design help workspace

  • Spellcheck code
    R rockram

    Thank you for your reply i do have a C# code on Spellcheck can u help me to get rid of errors: The Code follow below: using System; using System.IO; using System.Data; using System.Web.UI.WebControls; using System.Web.UI.HtmlControls; partial class Default2 : System.Web.UI.Page { private string[] strDictArray; private bool boolDictionaryLoaded = false; private int intErrors = 0; protected void Page_Load(object sender, System.EventArgs e) { int iCurrentCount = 0; string[] arrWords; string strCompleteOriginal = ""; int iWordCount = 0; string strAlternative = ""; int i = 0; if (Strings.Trim(Request.QueryString("txtContent")) == "") { return; // TODO: might not be correct. Was : Exit Sub } else { strCompleteOriginal = Strings.Trim(Request.QueryString("txtContent")); } if (!IsPostBack) { iCurrentCount = 0; iWordCount = 0; intErrors = 0; hfOriginalString.Value = strCompleteOriginal; hfCurrentCount.Value = "0"; arrWords = Strings.Split(strCompleteOriginal, " "); iWordCount = arrWords.Length; hfWordCount.Value = iWordCount; hfErrors.Value = "0"; } else { arrWords = Strings.Split(hfOriginalString.Value, " "); iCurrentCount = hfCurrentCount.Value; intErrors = int.Parse(hfErrors.Value); } txtCurrent.Value = arrWords(iCurrentCount); if (Request.Form("cmdCancel") == "Stop") { arrWords = Strings.Split(hfOriginalString.Value, " "); iWordCount = hfWordCount.Value; string strReplace = hfFinal.Value; int j = 0; for (j = iCurrentCount; j <= iWordCount - 1; j++) { strReplace += arrWords(j) + " "; } intErrors -= 1; stopChecking("frmSpellCheck", "txtContent", strReplace); return; // TODO: might not be correct. Was : Exit Sub } if (Request.Form("cmdNext") == "Next") { arrWords = Strings.Split(hfOriginalString.Value, " "); iWordCount = hfWordCount.Value; if (txtManual.Value == "") { arrWords(iCurrentCount) = lbSuggestions.SelectedValue; hfFinal.Value += lbSuggestions.SelectedVal

    ASP.NET csharp

  • Spellcheck code
    R rockram

    Provide me Spellcheck code in C# for web Applications(VS2005) Immediately

    ASP.NET csharp
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups