|
Hi!
We are seriously looking for an obfuscator. Most solutions are very expensive, but Xenocode[^] is fair priced. Anyone has an opinion on it?
Also, we're not sure if we should buy the basic or enterprise edition. The only feature we'd need in Enterprise would be string encryption, but then again... I'm not sure if we really need this. The basic edition included the ability to crash ILDASM. Would that be enough?
Our application is distributed to a small number of customers (about 50 small businesses).
Is there any other solution in the same price range I should check out?
Thanks!
Carl
|
|
|
|
|
In the follow code:
hDevInfo = SetupDiGetClassDevs(ptrGUID,
null,
null,
DIGCF_PRESENT|DIGCF_DEVICEINTERFACE);
if( hDevInfo == INVALID_HANDLE_VALUE)
{
MessageBox.Show("Can not get information set of this device class!", "ERROR", MessageBoxButtons.OK, MessageBoxIcon.Error);
return;
}
how to define INVALID_HANDLE_VALUE in my c# code?
|
|
|
|
|
Within your class define the value as the following:
private const UInt32 INVALID_HANDLE_VALUE = 0xffffffff;
- Nick Parker My Blog | My Articles
|
|
|
|
|
Hi!Nick,
Thank you very much!I have settled this matter under your help.
Now when I finished my code,I found a nother problem,which I posted it on this board as you can see.
I hope you can give me some tips.
Thank you again!
Best regards!
momer
|
|
|
|
|
Hello,
Now, I develop a tool, this have a button. button's back color is black. When a mouse pointer is on the form( worked mouseEnter event ), button's back color changed white. When a mouse pointer leave a button, button's back color changed black. After that clicked, showInTaskBar is true(when tool start, showInTaskBar is false).
This tool have a problem. Before a button click, mouse event is enable. But after a button click, mouse event is disable.
The following is the code.
private void button1_MouseLeave(object sender, System.EventArgs e)
{
button1.BackColor=Color.Black;
}
private void button1_MouseEnter(object sender, System.EventArgs e)
{
button1.BackColor=Color.White;
}
private void Form1_Load(object sender, System.EventArgs e)
{
this.ShowInTaskbar=false;
}
private void button1_Click(object sender, System.EventArgs e)
{
this.ShowInTaskbar=true;
}
I tried to escape this problem, so I investigate it. But I don't know.
I'd like to do "after a button click, mouse event is enable".
If you have some idias, tell me, please.
cheers,
yu-yu
|
|
|
|
|
Well, you can't disable mouse events, so, the problem is with your code not matching up with what you want to do. What EXACTLY are your trying to do?
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hello,
Thank you for your mail.
I try to do the following.
1.Usually enable mouse events.
2.Want to change showInTaskBar flag.
So, I develop the tools.
Cheers,
yu-yu
|
|
|
|
|
Hello,
I found this solution.
I make the following code in Button_Click().
private void button1_Click(object sender, System.EventArgs e)
{
Controls.Remove(button1);
this.ShowInTaskbar=!this.ShowInTaskbar;
Controls.Add(button1);
}
Thank you,
yu-yu
|
|
|
|
|
yu-yu wrote:
private void button1_Click(object sender, System.EventArgs e)
{
Controls.Remove(button1);
this.ShowInTaskbar=!this.ShowInTaskbar;
Controls.Add(button1);
}
You don't need to add and remove the button. All you need is the ShowInTaskbar line you have. Removing and adding the button will not change anything.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hello Dave,
I don't want to add and remove the button.
But I think to change ShowInTaskBar flag change is changing windows handle, so this condition occuered.
To escape it, I think resetting object. But this solution have limit.
Do you have some ideas ?
yu-yu,
|
|
|
|
|
Hi Everybody,
I have created a client form and webservice application. Now, If there will be a new update or feature on the client side, I don't want to install everything again on the client, in short, I want my web service to update the client automatically. What do you think is the best approach for this type of scenario?
Thanks and sorry for my bad english.
|
|
|
|
|
Since an application cannot overwrite itself when executing you create a small launcher exe that will start the actual application. The launcher needs to be designed in a way so that it will never need to be updated. From here you have to make a decision:
A) Application will notify the user and shutdown after acquiring the new files. User will have to start application again manually.
- Launcher will call file copy code on startup before any assemblies are loaded.
- Launcher will load atual application using reflection.
B) Application will automatically reload assemblies and continue running. No user input will be required for restarts.
- Launcher will load actual application into a seperate AppDomain with ShadowFileCopy set to true.
- When all data is downloaded the launcher will start file copy process.
- When file copy process is complete the original AppDomain will be unloaded and new one will be started.
You have to use an AppDomain because you cannot unload individual assemblies. However you can unload the whole AppDomain . ShadowFileCopy enabled you to write over the files on disk.
Things to consider:
- downloading method
- security. can anyone download your app for free?
- downloading on slow connections
- when to check for updates (startup, poll server?)
- how to check for updates (data provided through webservices, data hosted in file on webserver)
This posting is provided "AS IS" with no warranties, and confers no rights.
Alex Korchemniy
|
|
|
|
|
How to limit a TextBox control to a specific number of characters per line and number of lines?
please guide
|
|
|
|
|
MaxLength is the only built in feature for limiting amount of text in the TextBox . You'll have to create your own code to achieve what you want.
You can get the number of lines in the textbox by sending the EM_GETLINECOUNT message.
This posting is provided "AS IS" with no warranties, and confers no rights.
Alex Korchemniy
|
|
|
|
|
Hello,
I have a database application and have been experiencing problems adding, updating, and deleting using the data table.
Is there a more efficient and robust way to do this. My code l have used is listed below. Someone told me it is better to use the dataset rather than the datatable. If this is so would it be possible to convert the below code to using the dataset. I am not sure on how to use the syntax.
cnnTeacher.ConnectionString = @"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\IBS Library System\LibrarySystem.mdb;Persist Security Info=False"; <br />
OleDbDataAdapter daTeacher = new OleDbDataAdapter("SELECT * FROM Teacher",cnnTeacher);<br />
OleDbCommandBuilder cbTeacher = new OleDbCommandBuilder(daTeacher);<br />
daTeacher.Fill(dtTeacher);<br />
<br />
DataRow drNewTeacher = dtTeacher.NewRow();<br />
<br />
drNewTeacher["TeacherID"] = txtAddIDNumber.Text;<br />
drNewTeacher["FirstName"] = txtAddFirstName.Text;<br />
drNewTeacher["LastName"] = txtAddLastName.Text;<br />
drNewTeacher["E-mail"] = txtAddEmail.Text;<br />
<br />
dtTeacher.Rows.Add(drNewTeacher);<br />
daTeacher.Update(dtTeacher);
Many thanks in advance,
Steve
|
|
|
|
|
Hi,
I am working on a application in that we need to read client information. I stuck some where, i dont want to write a java script as i want to read client information from serveritself.
i have a doubt that,
Can we read the client time and clientzone information without writting a java script?
If anyone can guide me regarding this problem...
Thanks
Vaibhav
|
|
|
|
|
|
Please try the ASP.NET forum, you will get quick responses for this over there.
Salil Khedkar [^]
|
|
|
|
|
I have an application with a number of .NET DataGrid instances. I allow the user to dynamically resize the DataGrids at runtime. When this happens the scrollbar appear and disappear at will. I am sure this is supposed to be a convenience, but in my application it is indeed a nuisance.
Can anyone tell me how to turn on and turn off the scrollbars for a .NET DataGrid?
I am programming in C#, and tried calling ShowScrollBar from the WIN32 API. However, this seems to control a different set of scrollbars which are normally turned off anyway. If I pass a "true" for the last parameter I get two sets of scrollbars - 2 horizontal and two vertical. If I pass a "false", the same old DataGriod scrollbars are still there.
Any help would be appreciated.
Thanks,
Mark Mokris
|
|
|
|
|
|
I've been ripping my hair out for a couple of days with a scrolling issue and so I thought it was time to admit defeat and ask for help
If you notice, in the Visual Studio IDE when you drag the vertical scrollbar up or down, the window moves up or down exactly one line at a time - the small movements inbetween seem to be ignored.
However if you try the same with a richtextbox the window scrolls a very small amount at a time meaning that you might be left with half a line of text showing either at the top or bottom of the window.
How do I go about getting the richtextbox to scroll exactly one line at a time when the scrollbar is dragged?
I've tried all sorts, such as intercepting SB_THUMBTRACK, WM_VSCROLL etc, but I just can't figure out how to do it
TIA.
Cheers,
Paul Wilson
|
|
|
|
|
Im praying this doesn't mean no-one knows
Cheers,
Paul Wilson
|
|
|
|
|
Hallo
I try to write a window application that connect to database with udl.
The connection is O.k (I tested it), but when I want to use it in my code, it failed.
my code:
static SqlConnection con = new SqlConnection();
con.ConnectionString = "File Name=C:\\WINNT\\myConnection.udl;";
con.Open();
I also tried:
con.ConnectionString = @"File Name=C:\WINNT\PrePaidDb.udl;";
and also try to define it in app.setting.
the error is always:
{"Keyword not supported: 'file name'." }
Do someone has any idea.
Thanks a lot
|
|
|
|
|
The SqlConnection class doesn't support the File Name connection string parameter, thus it would fail. You can do this with the OleDbConnection class however:
OleDbConnection conn = new OleDbConnection(@"File Name = c:\test.udl");
try
{
conn.Open();
if(conn.State == ConnectionState.Open)
{
MessageBox.Show("Connection successful.");
}
}
catch(Exception ex)
{
MessageBox.Show(ex.Message);
}
finally
{
conn.Close();
}
- Nick Parker My Blog | My Articles
|
|
|
|
|
Thank you Nick.
The DB is in SqlServer and not in Access, is that means that I couldn't use udl to create connection?
|
|
|
|