> Hai ,
>
[quoted text clipped - 8 lines]
> strformula. it's urgent and reply immediately.
> Thanks in advance.
As you spelled "string" with a lower case 's', I'll assume you're writing in
C++.
You need to research the member functions available in the C++ string class.
particularly the various overloads of the find() function and the replace()
function..
If my assumption above is incorrect, please tell us which language and class
library you are using.

Signature
Peter [MVP Visual Developer]
Jack of all trades, master of none.
Kadaitcha Man - 12 Feb 2006 01:47 GMT
pvdg42 <pvdg42@newsgroups.nospam>, the boozing skid-row bum and
double-jointed lick-spigot who likes wretched nad sack sucking with
cadavers, and whose partner is a pink pants with a puffy divit, wrote in
<#K8rRFyLGHA.676@TK2MSFTNGP10.phx.gbl>:
>> Hai ,
>>
[quoted text clipped - 16 lines]
> If my assumption above is incorrect, please tell us which language
> and class library you are using.
lol

Signature
Cooking tonight: Beastly earwax balls and garlic extract garnished with
ravished English sparrow carbuncle and mole ulcer extract, served in a
chilled skillet brimming with chewy pieces of sea slug and eggplant in
noxious stinking slime, a side of bread and a keg of green turtle drool.
ksrajalakshmi@gmail.com, the perspiring chiseler and thick-skulled brown
rod who likes vulgar 69ers with caribous, and whose partner is a
flesh-peddler with a slushy bunny tuft, wrote in
<1139643024.132357.104660@g47g2000cwa.googlegroups.com>:
> Hai ,
>
[quoted text clipped - 8 lines]
> strformula. it's urgent and reply immediately.
> Thanks in advance.
From the *HELP* *TEXT*...
Visual Basic
' This example demonstrates the String.Contains() method
Imports System
Class Sample
Public Shared Sub Main()
Dim s1 As String = "The quick brown fox jumps over the lazy dog"
Dim s2 As String = "fox"
Dim b As Boolean
b = s1.Contains(s2)
Console.WriteLine("Is the string, s2, in the string, s1?: {0}", b)
End Sub 'Main
End Class 'Sample
'
'This example produces the following results:
'
'Is the string, s2, in the string, s1?: True
'
C#
// This example demonstrates the String.Contains() method
using System;
class Sample
{
public static void Main()
{
string s1 = "The quick brown fox jumps over the lazy dog";
string s2 = "fox";
bool b;
b = s1.Contains(s2);
Console.WriteLine("Is the string, s2, in the string, s1?: {0}", b);
/*
This example produces the following results:
Is the string, s2, in the string, s1?: True
*/
C++
// This example demonstrates the String.Contains() method
using namespace System;
int main()
{
String^ s1 = "The quick brown fox jumps over the lazy dog";
String^ s2 = "fox";
bool b;
b = s1->Contains( s2 );
Console::WriteLine( "Is the string, s2, in the string, s1?: {0}", b );
/*
This example produces the following results:
Is the string, s2, in the string, s1?: True
*/
Visual Basic
' Sample for String.IndexOf(Char, Int32)
Imports System
Class Sample
Public Shared Sub Main()
Dim br1 As String =
"0----+----1----+----2----+----3----+----4----+----5----+----6----+-"
Dim br2 As String =
"0123456789012345678901234567890123456789012345678901234567890123456"
Dim str As String = "Now is the time for all good men to come to the
aid of their party."
Dim start As Integer
Dim at As Integer
Console.WriteLine()
Console.WriteLine("All occurrences of 't' from position 0 to {0}.",
str.Length - 1)
Console.WriteLine("{1}{0}{2}{0}{3}{0}", Environment.NewLine, br1, br2,
str)
Console.Write("The letter 't' occurs at position(s): ")
at = 0
start = 0
While start < str.Length AndAlso at > - 1
at = str.IndexOf("t"c, start)
If at = - 1 Then
Exit While
End If
Console.Write("{0} ", at)
start = at + 1
End While
Console.WriteLine()
End Sub 'Main
End Class 'Sample
'
'This example produces the following results:
'
'All occurrences of 't' from position 0 to 66.
'0----+----1----+----2----+----3----+----4----+----5----+----6----+-
'0123456789012345678901234567890123456789012345678901234567890123456
'Now is the time for all good men to come to the aid of their party.
'
'The letter 't' occurs at position(s): 7 11 33 41 44 55 64
'
'
C#
// Sample for String.IndexOf(Char, Int32)
using System;
class Sample {
public static void Main() {
string br1 =
"0----+----1----+----2----+----3----+----4----+----5----+----6----+-";
string br2 =
"0123456789012345678901234567890123456789012345678901234567890123456";
string str = "Now is the time for all good men to come to the aid of
their party.";
int start;
int at;
Console.WriteLine();
Console.WriteLine("All occurrences of 't' from position 0 to {0}.",
str.Length-1);
Console.WriteLine("{1}{0}{2}{0}{3}{0}", Environment.NewLine, br1, br2,
str);
Console.Write("The letter 't' occurs at position(s): ");
at = 0;
start = 0;
while((start < str.Length) && (at > -1))
{
at = str.IndexOf('t', start);
if (at == -1) break;
Console.Write("{0} ", at);
start = at+1;
Console.WriteLine();
/*
This example produces the following results:
All occurrences of 't' from position 0 to 66.
0----+----1----+----2----+----3----+----4----+----5----+----6----+-
0123456789012345678901234567890123456789012345678901234567890123456
Now is the time for all good men to come to the aid of their party.
The letter 't' occurs at position(s): 7 11 33 41 44 55 64
*/
C++
// Sample for String::IndexOf(Char, Int32)
using namespace System;
int main()
{
String^ br1 =
"0----+----1----+----2----+----3----+----4----+----5----+----6----+-";
String^ br2 =
"0123456789012345678901234567890123456789012345678901234567890123456";
String^ str = "Now is the time for all good men to come to the aid of
their party.";
int start;
int at;
Console::WriteLine();
Console::WriteLine( "All occurrences of 't' from position 0 to {0}.",
str->Length - 1 );
Console::WriteLine( "{1}{0}{2}{0}{3}{0}", Environment::NewLine, br1, br2,
str );
Console::Write( "The letter 't' occurs at position(s): " );
at = 0;
start = 0;
while ( (start < str->Length) && (at > -1) )
{
at = str->IndexOf( 't', start );
if ( at == -1 )
break;}
Console::Write( "{0} ", at );
start = at + 1;
Console::WriteLine();
}
/*
This example produces the following results:
All occurrences of 't' from position 0 to 66.
0----+----1----+----2----+----3----+----4----+----5----+----6----+-
0123456789012345678901234567890123456789012345678901234567890123456
Now is the time for all good men to come to the aid of their party.
The letter 't' occurs at position(s): 7 11 33 41 44 55 64
*/

Signature
Cooking tonight: Dishonoured mule giblet and baboon nostril preserve
garnished with nearly raw live rat embryos and clove topping accompanied
by gone off carbuncle on top of packed-up koala droppings with clove
vinaigrette accentuated with underdone marten puddings and north
american porcupine eye conserve, served in a turbid tureen filled with
chewy bits of heart, veal and lamb in disgusting goo, a side of chipmunk
cervix and a pitcher of an unidentifiable organ juice.