|
As Andrei said, ofuscating prevents your codes to be decomplied (to some extent).
But remember that when you use the source of the dll (i.e. class.cs) in your project file, in fact no dll is built!! The source code is compiled and linked into your executable file!!
This is where the difference comes from.
|
|
|
|
|
I create my dll file in Class Library Project and use that Dll file in my asp.net web application.
I dont know anything about "ofuscating" please guide me more.
|
|
|
|
|
mohandesmehran wrote: I dont know anything about "ofuscating" please guide me more.
Google it. There are many different tools out there to help obfuscate your code.
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
hi.
in DateTime.Now , Now is a property. But when we set a dot after Now we can see a list of methods and properties, such as DateTime.Now.AddDay() , DateTime.Now.Date , DateTime.Now.AddMonth()
how can I do it?
thanks
mehran
|
|
|
|
|
If you have looked carefully at the type returned by the Now property, you might have seen that it's a DateTime object, which has properties and methods. So if you want to create a property that "has methods" you just need to create a property that returns an object that has other properties and methods.
Hope it helps.
I will use Google before asking dumb questions
|
|
|
|
|
|
This is so simple!
DateTime.Now is of type of class 'Date' which has itself different properties and methods!
You can create a class, and add any methods or properties in that class.
In an other class, now you may have a property of the latter class type.
|
|
|
|
|
I have to read the last 5 lines of several very very huge ASCII files, several times.
I want to see if it is possible to read only those last lines, instead of reading the whole junk data and getting to those 5 ending lines.
Could someone please help me, how to decrease this amount of waste of cpu time and un-wanted I/O?
|
|
|
|
|
You could set the position in the stream, but im not sure how accurate that would be.
The position is the current index in the huge array of bytes that is your text file, so if you knew the length of the text file...
For example, you have a text file with 5000 characters in it, you set the position too 4500, and then read the last 500 characters. That way you don't need to waste time reading the first 4500 characters.
The only problem is, how do you know where to start reading from? I'll leave that to you
to set the position, i think its just:
myStream.Position = somewhere;
I think it's .Position anyway, it might be .Location, i'm sure you'll find it.
My current favourite word is: PIE!
Good ol' pie, it's been a while.
|
|
|
|
|
Yes, and there is also .Length
A) Set the Position to Length
B) Read backward until you encounter the fifth newline
C) Reverse the string
|
|
|
|
|
Thank you!
This looks so fine!
|
|
|
|
|
Hi all,
Can any one advise me a free pdf library for creating pdf files. Which one is the best?
Regards
Zafer
|
|
|
|
|
This Google[^] turns up a bit.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
hello
i want to assign a custom source which is a table column of a dataset to a combo box. i know how to do it programmatically but i need to do it from the autocomplete source property of the combo box. also if i want to assign the custom source to a list box, what should i do
thanx
haseeb
|
|
|
|
|
Hi,
i created an App that will send eails using outlook.the matter of the can be typed inside a textbox and on the buttin click event it sends the mail.Its working fine no issues
But my problem here i want to replace the textbox with a Datgrid.
I will be inserting the details directly in to the datagrid and on the button click event this datagrid should be sent.
Attached along os teh code for the app .This code will send mails form the text box.
I want it to send froma datagrid.
Can anybody tell me how we can do it?
namespace Email_TestApp
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void btnSend_Click(object sender, EventArgs e)
{
try
{
MailMessage msgMail = new MailMessage();
msgMail.IsBodyHtml = true;
//msgMail.CC.Add(new MailAddress("axn@ts.com"));
//msgMail.Bcc.Add(new MailAddress("nx@ts.com"));
msgMail.To.Add(new MailAddress("jx@ts.com"));
msgMail.Subject = "Is My App Working?";
msgMail.Body = txtMail.Text;
SmtpClient objSmtpClient = new SmtpClient("smtp.atia.com");
objSmtpClient.Host = "smtp.atia.com";
objSmtpClient.Credentials = new NetworkCredential("tendors@atia.com", "password");
objSmtpClient.Send(msgMail);
}
catch (Exception ex)
{ }
}
Thanking You
|
|
|
|
|
hello... i think u have to combine the data of the datagrid into a string object and then send that.... how much detail are u planning of sending.. if u have one row one column then try somethin like
string str=urDataGrid.rows[0].cells[0].value
or if u have one row multiple columns, try
string str="";
foreach(DataGridViewCells cell in urDataGridView.Rows[0].Cells)
str+= cell.Value;
or if u have multiple rows and multiple columns try
str="";
foreach(DataGridViewRows row in urDataGridView.Rows)
{
foreach(DataGridViewCells cells in row.Cells)
str+=cells.Value
str+="\n"
}
I havent tried it, but i bet id would work... u can use string.Format for formatting the string...
haseeb
|
|
|
|
|
Thanks Haseeb,will try that out and keep you posted
|
|
|
|
|
hi all
how to biuld textbox as active control and set the backcolore to it by using C# .Net
thanks for any body hellp me
Thaer
|
|
|
|
|
Hi,
You can set the active control of the form using following code :
this.ActiveControl = textBox1;
textBox1.BackColor = System.Drawing.Color.Black;
//this.ActivControl.BackColor = System.Drawing.Color.Black;
Thanks,
Gopal.S
|
|
|
|
|
|
Hi,
Can you please elaborate your question? An example might help.
|
|
|
|
|
Hi!
Simply: Generate a "regular" random number in the range [0...n[ with n being the number of elements in the array of values and use it as index into your array.
Regards,
mav
--
Black holes are the places where God divided by 0...
|
|
|
|
|
the minimum value should be 0 and the maximum value should be the length of array ( minus 1). Next generate the random number b/w the range and then use myarray[randomNo], to get a randomnly selected value from the array.
haseeb
|
|
|
|
|
Hello....i've been working in ado.net for a few months now... and am quite confused how to use the dataset object. though i know it depends on what type of project a person is upto but still i wanted to know which one is the better approach to usin the datasets...
Approach 1: fill the dataset with all tables at project load and use the dataset for all searches and things. though as sqlserver is locally placed, i update the sqlserver tables as soon as i update the data set...
Approach 2: fill dataset with only the rows that are required... ie if u need some rows according to a criteria, write a select statement, discard ur present dataset and refil it with this statement...
Please provide full information,based on performance issues of a system...
as far as i think , i believe approach1 will be better but it becomes hard to handle when u have more tables, like 60 tables... so wat should be done in this case, "A dataset for every 10 tables"? or wat...
Thanx
haseeb
haseeb
haseeb
|
|
|
|
|
This depends on the type of application you want to write. It's a good practice to minimize the queries to a database when you write a web application. But still, my opinion is that it's not a good practice to read all the data from the database into a dataset. What happens when you have around 50-60 tables and each table has 50.000 or more rows. In this case you do a huge waste of memory. I think it's better practice to save into a dataset all the data needed at a certain time. This is my opinion.
I will use Google before asking dumb questions
|
|
|
|