|
He can't do this[^], and he wants to make a CD copy protection scheme???? I've got to give him credit for having ambition!
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I am not sure how to achieve this:
In my VS 2k3 solution, I have about 12 projects and about 9000 methods. What I need to achieve is, for every method insert a try/finally block.
So, the following example shows before and after.
<big>
private void HelloWorld(int x, string y, object z)
{
}
<big>
private void HelloWorld(int x, string y, object z)
{
try
{
CallAutoMethod1(this, "HelloWorld");
}
finally
{
CallAutoMethod2(this, "HelloWorld");
}
}
My goal is to be able to get a trace of when the method was entered and when it was exited. I was initially planning on doing this as a pre-build event through VS macros (using VS APIs) but I do not want to modify the code. Any suggestions?
Can I modify the DLL assemebly and programmatically insert the try/finally?
And what I am trying to achieve cannot be accomplished through a Profiler. I have tried about dozen of them.
Thanks,
- Malhar
|
|
|
|
|
Search for PERWAPI on Google
|
|
|
|
|
Hi all !
when I have "one" DataGrid in my form , for change of Header Text of GridColumn in a DataGrid i do this :
in Property of DataGrid > TableStyles(Collection) > GridColumnStyles > HeaderText
But when I have 2 DataGrid for 2 table that there is a relation "one to many" between them , I can't change the Header Text of GridColumn .
very thanks for any help !
Regards
s_mostafa_h
-- modified at 16:56 Thursday 16th February, 2006
|
|
|
|
|
you could try and add the alias names in your SQL script. Select PO AS [Purchase Order] from POS.
T
Tom Wright
tawright915@yahoo.com
|
|
|
|
|
can you explain more about this ?
very thanks
s_mostafa_h
|
|
|
|
|
Hi.
I want in Install time of my application, if .net framework is not installed, It auotomatically install.
OK, VS2005 do this, but in one stage it gives Accept of EULA, and I want to install framework silent(In background), and user don't understand anything.
In framework 1.1 we had a command, but in framework 2 what?
It is very important for me that in time of installing framework 2 , user don't accept that EULA.
Best wishes
|
|
|
|
|
mehrdadc48 wrote: It is very important for me that in time of installing framework 2 , user don't accept that EULA.
If the used doesn't (or can't) accept the EULA for the .NET Framework then they are not licensed to use it. You are putting both your self and your users in legal jeapordy. Yourself because you are intentionally installing software on your user's machine without their consent, and your users because they will have software that they are not licensed to use (because they were never able to accept or decline the license).
IF the redistributable license stated that when you redistribute the framework the end user MUST accept the EULA for the .NET Framework, then, even if you find a technical workaround, you still do not have a legal workaround.
ColinMackay.net
Scottish Developers are looking for speakers for user group sessions over the next few months. Do you want to know more?
|
|
|
|
|
Hello,
I'm trying to write a little tool for my automated builds that will open all AssemblyInfo.cs files in my solution and update the revision part of the AssemblyVersion attribute.
I'm currently reading the file line by line, and I want to identify this text:
[assembly: AssemblyVersion("x.xx.xx.0")] (where x is a digit that must stay the same) and use Regex.Replace (or whatever) to change it to
[assembly: AssemblyVersion("x.xx.xx.revision_number")] I've been looking around for the past 20 minutes and I just gave up. For sure someone here must know the answer of the top of his head.
So, any ideas? Thanks!
-- LuisR
Luis Alonso Ramos
Intelectix - Chihuahua, Mexico
Not much here: My CP Blog!
The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005
-- modified at 15:41 Thursday 16th February, 2006
|
|
|
|
|
Try this:
using System;
using System.Text.RegularExpressions;
namespace ConsoleApplication4
{
class Program
{
static void Main(string[] args)
{
string revision_number = "1";
Regex r = new Regex(@"(\d+\.\d+\.\d+\.)\d+");
Match m = r.Match("1.23.44.0");
if (m.Success)
{
string newVersion = m.Groups[1].Value + revision_number;
Console.WriteLine(newVersion);
}
}
}
}
--------
"I say no to drugs, but they don't listen."
- Marilyn Manson
|
|
|
|
|
Use this pattern to find the string: "\\[assembly: AssemblyVersion\\(\"(\\d.\\d\\d.\\d\\d).0\"\\)\\]".
---
b { font-weight: normal; }
|
|
|
|
|
Luis Alonso Ramos wrote: I'm trying to write a little tool for my automated builds that will open all AssemblyInfo.cs files in my solution and update the revision part of the AssemblyVersion attribute.
Please share when you are done :p I am also getting tired of this :p
|
|
|
|
|
Thanks to Guffa and Michel I got it to work now. I'll try to write a little article for it on the weekend and post it here.
-- LuisR
Luis Alonso Ramos
Intelectix - Chihuahua, Mexico
Not much here: My CP Blog!
The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005
|
|
|
|
|
Thanks, I will look out for it!
|
|
|
|
|
I have an application where I have a DataGridView with the first row frozen. Something like this:
myDataGridView.Rows[0].Frozen = true;
myDataGridView.Rows[0].DefaultCellStyle.BackColor = SystemColors.Info;
</code>
I have two problems with this. First when you sort it seems to lose the BackColor but the new first row is still frozen which is rather odd. I don't know why the first row is keeping some properties (i.e. the frozen state) but losing others (i.e. it's cell style).
The second problem is that ideally I'd like to be able to sort everything except the first row. The DataGridView is bound to a DataTable and I'm not sure if there is an easy way to do this.
Any ideas?
-- modified at 14:52 Thursday 16th February, 2006
|
|
|
|
|
Process.WaitForExit() is a blocking call. Is there a nonblocking equivilant, or will I need to call the 2nd app from a thread. I need to know when it's finished so that I can clean up the temp files I created for it as input.
|
|
|
|
|
You can handle Process.Exited event. like this:
<br />
Process notepadProcess;<br />
private void button1_Click(object sender, EventArgs e) {<br />
notepadProcess = new Process();<br />
notepadProcess.EnableRaisingEvents = true;
notepadProcess.Exited += new EventHandler(notepadProcess_Exited);
notepadProcess.StartInfo.FileName = "notepad.exe";<br />
notepadProcess.Start();<br />
}<br />
void notepadProcess_Exited(object sender, EventArgs e) {<br />
MessageBox.Show("Notepad process just has been exited.");<br />
notepadProcess.Dispose();<br />
}<br />
Robin Panther http://www.robinland.com
|
|
|
|
|
Thanks. I figured there had to be a more graceful way to do it.
|
|
|
|
|
private DateTime tStart, tEnd;
tStart=DateTime.Now;
//programs....
tEnd=DateTime.Now;
I will output tStart and tEnd to a txt file, can caculate the running time by hand in hours and minutes. Is there I can calculate the time first then output it to the txt file.
THX
|
|
|
|
|
Use the TimeSpan class.
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
hi
if i can't inject process to other process in c#.net , how to solve my problem ??
My problem is :
i want to write program that get one exe file and convert to dat file and create loader and checker file (3 file created : dat file,loader file and checker file)
loader file is almost blank process and when it executed , it check the checker file and if conditions is true the .dat file inject into loader until that orginal exe is run (like TZ Executable Protector)
//// How to do this ?
and if you have any idea for solve my problem (executable header,stream encryption/decryption or ...)
how to do that and give me an example or source ...
|
|
|
|
|
Why don't do drop this scheme and use a commercial product written by people who are Windows Internals professionals?? You're not going to get any answers that you consider "acceptable" and spamming the forums with the same question will not get you any closer to the answer. The technology that you're talking about is not just documented anywhere. In fact, it's NOT DOCUMENTED at all! There is a reason why these companies can charge what they do for a security wrapper like this!
It's clear that you don't have the black-belt-level of knowledge needed of the PXE file format, Windows Loader, unmanaged code, and what-not, to pull this off. And 99.9999% of the rest of the world doesn't either! You're trying to build something that is beyond the experience of most people you'll find on this, or any other board.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
-- modified at 16:52 Thursday 16th February, 2006
|
|
|
|
|
Dave Kreskowiak wrote: It's clear that you don't have the black-belt-level of knowledge
But he is persistant.
He's now changed tactic[^]. I'm now curious about what he is actually trying to build.
ColinMackay.net
Scottish Developers are looking for speakers for user group sessions over the next few months. Do you want to know more?
|
|
|
|
|
I'll give him that much! But there comes a point in time where you just have to realize that the effort you putting into a project/feature to get a certain payoff just isn't worth the money you're pouring into it!
What's up with this guy??!! What's he tring to do with this junk??
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
-- modified at 20:17 Thursday 16th February, 2006
|
|
|
|
|
hi!
i've loaded two meshes and one of them should be 75% transparent
the other mesh moves behind that mesh.
i can see the backgroundcolor through the first mesh but i can't see the second mesh
after i created the device i set
dev.RenderState.SourceBlend = Blend.SourceAlpha;
dev.RenderState.DestinationBlend = Blend.InvSourceAlpha;
dev.RenderState.AlphaBlendEnable = false;
when i load the first mesh i enable the alphablend, draw the mesh and disable it again
if(meshMaterials[i].Ambient.A < 60)
dev.RenderState.AlphaBlendEnable = true;
mesh.DrawSubset(i);
dev.RenderState.AlphaBlendEnable = false;
what can i do to see the second mesh moving behind the first one?
thanks, kopi_b
|
|
|
|