Ramy Mahrous 401 Postaholic Featured Poster

Again, a database is your solution. XML and directory but users can delete\replace or play with directory which then your assembly well not behave well.

Ramy Mahrous 401 Postaholic Featured Poster
System.IO.File.AppendAllText(filePath, content);

In your case

System.IO.File.AppendAllText(@"c:\TestFile.txt", txtOutput.Text);
Ramy Mahrous 401 Postaholic Featured Poster

What's the type of application?!

Ramy Mahrous 401 Postaholic Featured Poster

It's not tooltip it's documentation

/// <summary>
/// Adds two operands and return the sum
/// </summary>
/// <param name="op1">First operand</param>
/// <param name="op2">Second operand</param>
/// <returns>The sum</returns>
private static float Add(float op1, float op2)
{
throw new NotImplementedException();
}

if you write Add it'd show the above documentation

DON'T WRITE ANY METHOD WITHOUT DOCUMENTATION, it's help who come after you understand it very well.

How to do: write three slashes (///) above the method.

Ramy Mahrous 401 Postaholic Featured Poster

Can you please try that on SSMS, and see what happens? it may there something wrong from C#.

Ramy Mahrous 401 Postaholic Featured Poster

What are you doing is called satellite dll which holds some resources to another programs it's OK, but for your scenario I find database is scalable more than using satellite dll. what if you user needs to add some pictures to your image collections? if you are using satellite dll you need to do intermediate class to talk to both .resx and external application and this intermediate class can handle naming and so on.

Ramy Mahrous 401 Postaholic Featured Poster

Let your windows application call the demo application. work around it.

Ramy Mahrous 401 Postaholic Featured Poster
Ramy Mahrous 401 Postaholic Featured Poster

It's independent ETL solution by Microsoft but from any source to any destination and you don't need to have SQL Server as software or staging to move data, I highly recommend you to use it, any help regarding this I'm here.

Ramy Mahrous 401 Postaholic Featured Poster

what about SSIS? I didn't use SSMA.
You can use SSIS to move\copy data in fast and smooth way.

Ramy Mahrous 401 Postaholic Featured Poster

I know both restrictions but I've no exact information about their project.

Ramy Mahrous 401 Postaholic Featured Poster

My pleasure, Serkan :)

Ramy Mahrous 401 Postaholic Featured Poster

Diamonddrake, I understand multithreading well but the asker didn't mention if they use usercontrol or just call a method, if they say drag and drop this control on form it means usercontrol initiated in a thread which is different than the thread inteact with this usercontrol and we need to customize the code. but all in all in many cases I don't exactly answer the question well because I'm not with the developer who faces the problem, in my entire life if someone face a problem I meet them and stay to solve the problem together.

Ramy Mahrous 401 Postaholic Featured Poster

My pleasure friend, search on Solved in this page I think I can't tell you its location :)

Ramy Mahrous 401 Postaholic Featured Poster

No friend it's poosible.
From ComboBox properties let
AutoCompleteMode = SuggestAppend
AutoCompleteSource = ListItems

jen140 commented: Thanks for help =) +1
serkan sendur commented: very good solution +4
Ramy Mahrous 401 Postaholic Featured Poster

Sorry I forgot something try this

Extract_ButtonHandler_Click(object sender, EventArgs e)
{
thrd = new Thread(new ThreadStart(ExtractFrames));
thrd.Start();
}
Ramy Mahrous 401 Postaholic Featured Poster

Just I need to make sure of something but I'll tell you to work with multithreading without using BackgroundWorker component

Thread thrd;
Extract_ButtonHandler_Click(object sender, EventArgs e)
{
thrd = new Thread(new ThreadStart(ExtractFrames));
}
string outPath = "you path";
///Extracts frames and saves them in directory
void ExtractFrames()
{
foreach (FrameGrabber.Frame f in fg)//error in this line highlighting "in"
{
using (f)
{
picBoxFrame.Image = (Bitmap)f.Image.Clone();
f.Image.Save(System.IO.Path.Combine(outPath, "frame" + f.FrameIndex + ".bmp"), System.Drawing.Imaging.ImageFormat.Bmp);
//Application.DoEvents();
}
}
Cancel_ButtonHandler_Click(object sender, EventArgs e)
{
thrd.Suspend();
}

Try above code and tell me if you got an error, you may need to customize the code but I expect you'll understand the idea.

Ramy Mahrous 401 Postaholic Featured Poster

You mean when you don't use BackgroundWorker component everything runs well?

Ramy Mahrous 401 Postaholic Featured Poster

i will try to prove you wrong(upps this reminded me of some..)

I know this quote reminds you of whom :p

Ramy Mahrous 401 Postaholic Featured Poster

You can't. There's not way to do that.

Ramy Mahrous 401 Postaholic Featured Poster

Remove it from project references.

Ramy Mahrous 401 Postaholic Featured Poster

Yes, Just add reference from one to another not from both to both.

Ramy Mahrous 401 Postaholic Featured Poster

No, they shouldn't. You should add reference from Project1 to Project2 to be able to write using namespace MainProject.Project2; To add reference, from Project1 solution explorer references->add reference->browse to locate the project2 assembly or projects tab to get all assembles in all solution including project2 assembly.

Ramy Mahrous 401 Postaholic Featured Poster

Which technology you use? WCF or just socket programming what's the importance of data? all of these questions determine the best practice of implementing passing messages.

Ramy Mahrous 401 Postaholic Featured Poster

textBox1.Text = sr.ReadToEnd(); you say remove the text in the textbox1 then put instead the text in the file if you need to append it use textBox1.Text += sr.ReadToEnd();

Ramy Mahrous 401 Postaholic Featured Poster

Check from SQL Server Surface Area Configuration on the Server and check if it allows remote connections or not. Please mention exactly the exception you get.
Or
Change the connection string to "Data Source=192.168.0.10;database=mydatabase;User id=myuser;Password=pass"
Or check with the administration group 2301 is the SQL Server port or 1433?

Ramy Mahrous 401 Postaholic Featured Poster

Greate, Sknake

Ramy Mahrous 401 Postaholic Featured Poster

Open new query document and copy the script and paste it there.

Ramy Mahrous 401 Postaholic Featured Poster

edi843, You have lack in your logic design! how you need to achieve wrapping to class without accessing its methods?!

Ramy Mahrous 401 Postaholic Featured Poster

It's not override at all! it's wrapping classes with different names...

public class Parent
    {
        public void Add(object o) { //some code }

    }
    public class Child : Parent
    {
        public void Aggungi(object o)
        {
            base.Add(o);
        }
    }

*seems[text]

doesn't work!
[/text]

Ramy Mahrous 401 Postaholic Featured Poster

I want to override methodA of classA, but not with the name methodA, but with a different name,

So why do you need to override it :)?? method with different implementation with different name!!!

Ramy Mahrous 401 Postaholic Featured Poster
Ramy Mahrous 401 Postaholic Featured Poster

I need to have it as byte values, so the permutation needs to be 0a0b0c

It means that abc the binary file = 0a0b0c??
To get string bytes have a look
http://msdn.microsoft.com/en-us/library/system.text.asciiencoding.getbytes(VS.71).aspx

Ramy Mahrous 401 Postaholic Featured Poster

If you execute SQL Statement against SQLite, add distinct!! DataSet hasn't do to any much work over it carries data for you!

toadzky commented: Gave the correct solution. +3
Ramy Mahrous 401 Postaholic Featured Poster

If you tell me how you generate the permutations of length 6 (C# code) , I tell you how to do so with 4 and 5

Ramy Mahrous 401 Postaholic Featured Poster

DataSet?! SQLite doesn't have Distinct keyword?

Ramy Mahrous 401 Postaholic Featured Poster

Before binding

List<Object> dataAsObj = new List<Object>();
foreach(var x in Data)
{
if(!dataAsObj.Contains(x))
dataAsObj.Add(x);
}
cbb_City.DataSource = dataAsObj;
cbb_City.DisplayMember = "Accounts.City";
cbb_City.ValueMember = "Accounts.City";
Ramy Mahrous 401 Postaholic Featured Poster

Application not ApplicationClass!
== Microsoft.Office.Interop.Excel.Application xl = new Microsoft.Office.Interop.Excel.Application();

Ramy Mahrous 401 Postaholic Featured Poster

Add using Microsoft.Office.Interop.Excel;

Ramy Mahrous 401 Postaholic Featured Poster

OK, so mark it as solved!

Ramy Mahrous 401 Postaholic Featured Poster

You should place your value contains dashes in single quote '

string updateCommand = String.Format("UPDATE MyTable SET MyTable.Code  = '{0}' WHERE MyTable.ID = '{1}'","10-5-3","124" )
Ramy Mahrous 401 Postaholic Featured Poster

Or delete the Example.cs and repeat the steps to create new code file and paste the code into. Or simply replace existing code with new one.
Actually this is bad comment, ignore it!

Ramy Mahrous 401 Postaholic Featured Poster
Ramy Mahrous 401 Postaholic Featured Poster

Yes, Danny, it's Vista problem (Aero, and Vista basic) color scheme, if you turn it into Windows Classic it'd work.

Or, remove Vista style

[STAThread]
        static void Main()
        {
            //Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new Form1());
        }
ddanbe commented: Offered a plethora of solutions to the problem! +4
Ramy Mahrous 401 Postaholic Featured Poster
Ramy Mahrous 401 Postaholic Featured Poster

Do you have any triggers on those tables?

Ramy Mahrous 401 Postaholic Featured Poster

I understood you, you can use XMLTextReader

static void Main(string[] args)
        {
            string xmlStr = "<string xmlns=\"http://www.webserviceX.NET/\"><StockQuotes><Stock><Symbol>AAPL</Symbol><Last>121.30</Last><Date>4/21/2009</Date><Time>3:03pm</Time><Change>+0.80</Change><Open>118.95</Open><High>122.14</High><Low>118.60</Low><Volume>13044984</Volume><MktCap>108.0B</MktCap><PreviousClose>120.50</PreviousClose><PercentageChange>+0.66%</PercentageChange><AnnRange>78.20 - 192.24</AnnRange><Earns>5.383</Earns><P-E>22.39</P-E><Name>Apple Inc.</Name></Stock></StockQuotes></string>";
            PrintElmentValue(xmlStr, "Last"); //pass any element name i.e Last, Change, Symbol
        }

        static void PrintElmentValue(string strAsXml, string elmentName)
        {
            XmlTextReader reader = new XmlTextReader(new MemoryStream(new ASCIIEncoding().GetBytes(strAsXml)));

            while (reader.Read())
            {
                if (reader.NodeType == XmlNodeType.Element && reader.Name == elmentName)
                {
                    Console.WriteLine(reader.ReadInnerXml());
                }
            }
        }
Ramy Mahrous 401 Postaholic Featured Poster

Please tell me what string you get, and how you need it to be. Because messages (return value) from XML Webservice be in SOAP format, so I'm confused.

Ramy Mahrous 401 Postaholic Featured Poster

Did you mention you work with multithreading technique?
Please mark it as solved.

Ramy Mahrous 401 Postaholic Featured Poster

Strange!! Did you debug it?