Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~5K People Reached

19 Posted Topics

Member Avatar for bullet_1

I am very new to javascript I am creating a quiz form in which each question has four options. Ex: 1. What is your favourite sport ? A. Cricket B. Football C. Hockey D. Baseball When mouse over on options A, B, C, D bg color has to be appeared …

0
87
Member Avatar for bullet_1

In the following code, the pattern is reading text between specified tags and I want to replace text in between those specified tags. I tried but replacing in whole file. string input = File.ReadAllText(@"D:\text\div.txt"); string pattern = @"<body.*?>(.|\n)*?</body>";//reads text between specified tags MatchCollection matches = Regex.Matches(input, pattern); // Console.WriteLine("Matches found: …

Member Avatar for castajiz_2
0
2K
Member Avatar for bullet_1

1) <s>Hai Dani</s> 2) <s>HAI DANI</s> 3) <s>hai dani</s> This code gives correct output for only first sentence Selection.Find.ClearFormatting Selection.Find.Replacement.ClearFormatting With Selection.Find.Replacement .Font.SmallCaps = True End With With Selection.Find .Text = "\<s\>(*)\</s\>" .Replacement.Text = "\1" .Forward = True .Wrap = wdFindContinue .Format = True .MatchCase = False .MatchWholeWord = False …

0
89
Member Avatar for bullet_1

I am using following code to split a text file where the file path is provided through textbox string[] allFiles = System.IO.Directory.GetFiles(@"textBox1.Text); foreach (string file in allFiles) Regex.Split(textBox1.Text, {"<ty>"}); but getting an error My need is read a large text file and split it based on <th> tag and save …

Member Avatar for Momerath
0
201
Member Avatar for bullet_1

I am using the following code to create a log file but getting an error "User-defined type not defined" Help me Thanks in advance Sub main() Dim dDate As Date Dim boDP As busobj.DataProvider 'error occured Dim sLast As String Dim sFileName As String Dim sDir As String Dim dTime …

Member Avatar for bullet_1
0
278
Member Avatar for Abhishek_Singh

Private Sub ToggleButton1_Click() Dim fd As FileDialog Dim objfl As Variant Dim filnam As String Set fd = Application.FileDialog(msoFileDialogFilePicker) With fd .ButtonName = "Select" .AllowMultiSelect = False .Filters.Add "Text Files", "*.txt;*.csv;*.tab;*.asc" .Title = "Choose Transactions file to import" .InitialView = msoFileDialogViewDetails .Show For Each objfl In .SelectedItems filnam = objfl …

Member Avatar for bullet_1
0
313
Member Avatar for bullet_1

I can search and find text in word doc through vba but I dont understand how to search images Its a big problem to me Can anybody help me thanks in advance

Member Avatar for Zephaniah
0
135
Member Avatar for bullet_1

I am using following where it replaces entities like &lt with <, &gt with >, &alpha wth α but i need replace "<", ">", "@"......with unique codes like &#60; , &#62; .......... Public Function QuickRead(FName As String) As Variant Dim i As Integer Dim res As String Dim l As …

0
105
Member Avatar for bullet_1

I am using following code. It creates a macro button on word menu in Add-Ins tab Public Sub ShowToolbar() ' Assumes toolbar not already loaded ' Application.CommandBars.Add TOOLBARNAME AddButton "Button caption", "This is a tooltip", 526, "NameOfASubInYourVBACode" ' call AddButton more times for more buttons ' With Application.CommandBars(TOOLBARNAME) .Visible = …

Member Avatar for Begginnerdev
0
189
Member Avatar for bullet_1

I am using the following code which creates a toolbar button on excel menu. On button click it executes a macro Private Sub Command1_Click() ' Start Word Dim wdapp As Object 'Excel.Application Set wdapp = CreateObject("Word.Application") ' Make it visible... wdapp.Visible = True ' Add a new workbook Dim xlbook …

0
112
Member Avatar for bullet_1

I want to create a template file in which I want to create my own styles programatically(in VBA) I have following code Sub Style() Dim myStyle As Style Set myStyle = ActiveDocument.Styles.Add(Name:="Abbreviations", _ Type:=wdStyleTypeParagraph) With myStyle.Font .Name = "Calibri" .Size = 12 .Color = wdColorBlue End With Selection.Range.Style = "Abbreviations" …

Member Avatar for bullet_1
0
149
Member Avatar for bullet_1

I am using following code which is displaying all files in listbox. But only files with specified extension selected from combobox(i.e .txt or .html....) should be displayed private void button1_Click(object sender, EventArgs e) { string search = textBox1.Text; string folder = textBox2.Text; MessageBox.Show(comboBox1); string[] allFiles = System.IO.Directory.GetFiles(folder, "comboBox1");//Change path to …

Member Avatar for Fenrir()
0
190
Member Avatar for bullet_1

I am using following code. It displays date and time for each file in log. But I want it to display only once sw.WriteLine("File Name {0}", file); sw.Write("\r\nLog Entry : "); sw.WriteLine("{0} {1}", DateTime.Now.ToLongTimeString(), DateTime.Now.ToLongDateString()); sw.WriteLine ("-------------------------------"); The output is Log File : File Name D:\DotNet\test\1.txt Log Entry : 12:47:05 …

Member Avatar for bullet_1
0
202
Member Avatar for bullet_1

I am having an Html file in which there are some errors. I want all the errors to be dislayed in a log file can anybody help me thanks in advance

0
79
Member Avatar for bullet_1

I am using following code, it replaces entities in whole html file. But I want to replace only in between specified tags(i.e <div>......</div>) please help me { FileInfo n = new FileInfo(inputpath); string initContent = File.ReadAllText(file); int contentLength = initContent.Length; Matches m; while ((m = Regex.Matches(initContent, "[^a-zA-Z0-9<>=./\\s(&#\\d+;)-]")).Value != String.Empty) initContent …

Member Avatar for tinstaafl
0
165
Member Avatar for bullet_1

I am new to C# I want to replace Characters such as("' & < > ¡ ¢ £ ¤ ¥ ¦ § ¨ © ª « ¬ ² ³ ´ µ ¶ · ¸ and so on...) with entity numbers like (&#34; &#39; &#38; &#60; &#62; &#160; &#161; &#162; &#163; …

Member Avatar for bullet_1
0
167
Member Avatar for bullet_1

following code replaces Figure 1....so on with <a href=1>1</a> .....so on but want to replace this " <a href=1>1</a> " ....... with <a href="#fig1">Figure 1</a>....so on in single line declaration please help me public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void button1_Click(object sender, EventArgs …

Member Avatar for gusano79
0
184
Member Avatar for bullet_1

i am new to C# i want to replace Figure 1, Figure 2....... with <a href="#fig1">Figure 1</a>....... i used the following code but no desired output { string targetId = "1"; string pattern = @"(?<=<a[^>]+href=""Figure\?mId=(?<Id>" + targetId + @")(?="">)"; string replace = "<a href>Figure</a>?pId=${Id}"; string result = Regex.Replace(input, pattern, replace); …

Member Avatar for Momerath
0
174
Member Avatar for bullet_1

want to replace Figure 1, Figure 2 and so on ........ with <a href="#fig1">Figure 1</a> plz help me thanks in advance

Member Avatar for ChrisHunter
0
172

The End.