|
Hi All,
Does anybody know how to manipulate with the temporary internet files in .net
I found that there is a file called index.dat. I think this file describes the IE.content in the temporary internet files folder. Is there a way to retrieve the urls from the index.dat (or any other source)?
thanks a lot
Haleem
|
|
|
|
|
DataGridView controler ,
how to change row backcolor at run time?????????????????????
Thiwa
|
|
|
|
|
If you are talking about a GridView in a web project:
Access the RowDataBound event of the grid and
If the e.Row.RowType = DataControlRowType.DataRow Then <br />
e.Row.BackColor = Color.Red<br />
End If
If you talking about a DataGridView in a windows forms project:
If you want to change row colors specifically to alternate row colors, that feature is already built in. Just put something like this in your form load event:
Dim styleDefault As New DataGridViewCellStyle()<br />
styleDefault.BackColor = Color.White<br />
styleDefault.ForeColor = Color.Black<br />
styleDefault.SelectionBackColor = Color.White<br />
styleDefault.SelectionForeColor = Color.Black<br />
dgvMyGrid.DefaultCellStyle = styleDefault<br />
<br />
Dim styleAlternate As New DataGridViewCellStyle()<br />
styleAlternate.BackColor = Color.LightGoldenrodYellow<br />
styleAlternate.ForeColor = Color.Black<br />
styleAlternate.SelectionBackColor = Color.LightGoldenrodYellow<br />
styleAlternate.SelectionForeColor = Color.Black<br />
dgvMyGrid.AlternatingRowsDefaultCellStyle = styleAlternate
If you want to access a specific row and highlight it, just access the style directly: (intMyRowIndex is the row index of the cell you wish to highlight)
Dim styleTemp As New DataGridViewCellStyle<br />
styleTemp.BackColor = Color.Red<br />
styleTemp.ForeColor = Color.Black<br />
styleTemp.SelectionBackColor = Color.Red<br />
styleTemp.SelectionForeColor = Color.Black<br />
<br />
dgvMyGrid.Rows(intMyRowIndex).DefaultCellStyle = styleTemp
Hope this helps.
|
|
|
|
|
TAHNKS.......
I want to change color to specific row.
but my problem is deferent, Im open the Form using another button.
First time I run the program it works, but Im closed the from and open it again it not working????????????????
Why it happened?????????
Thiwa
|
|
|
|
|
Hi,
I want some instructions in converting existing C# Windows Application to C# Web Application..
Please post your replies as soon as possible.
|
|
|
|
|
If the application has been properly architected it should just be a matter of rewriting the presentation (UI) layer - perhaps with the odd addition elsewhere to support a stateless model of working. If it hasn't been well architected then you are looking at rewriting the whole application.
|
|
|
|
|
Spamming different 10 forums with the same question is very rude and totally unnecessary.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
I need to send reports to user in excel sheet format. so plz tell me the way how to convert my data into the excel file format,retrieved from database.
With Thanks & Regards
Amit Sk Sharma
|
|
|
|
|
|
Hello,
My project is about to check the some values in a word document and to open a new word document and type those values and to insert the BUTTON to close that document.
i finished inserting the Button and i dont know how to use that button to close,
I used this code to insert the command button
Selection.InlineShapes.AddOLEControl ClassType:="Forms.CommandButton.1"
Help me to proceed further....
Thanks,
Nanda
|
|
|
|
|
Hello!
I am going to finalize my application what I created with vb.net. However I have faced with an intrique problem about creating and integrating an activation code method. I don't use any database but a XML file to store
DateInstalled and ActivationStatus values in this file as encrypted data because I am not able to overwrite a resource field in my resource file in runtime. Even I use encrypted data in XML file this file can be edited by a user.
Lets assume that one user had installed the app on 3/20/2007 and second user had installed the app. on 3/29/2007. If first user has destroyed the data in XML file, the second user can pass his own XML file to first user with a most recent application installation date. How could you solve such problem? What would be your best approach as method to solve activation integration for your application? Where would you safely store such imported information?
Any advice is appreciated.
Thank You!
What a curious mind needs to discover knowledge is noting else than a pin-hole.
|
|
|
|
|
Because your app is .NET, any code you write to protect it can be decompiled and removed. The big question is, why do you think you need to take it this far ? How many people are going to try to steal your app ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
I am not concerned if anyone steals my application. All I was doing is to force my brain to come up with a suitable solution. I know there is no way to protect the app with hundred percent but at least I make things more complex for 3rd parties. I better keep working on it.
Thanks Christian.
What a curious mind needs to discover knowledge is noting else than a pin-hole.
|
|
|
|
|
Hi,
Like you said, you can only make it more difficult, never impossible. Perhaps the simplest way to accomplish what you want, is building in more layers.
For example, you could add another xml file, with a nondescript name, and record the last access dates of all other files in the installation folder, upon installation.
At the moment your app checks for the date, you can cross reference it to the last access date of the xml file. If the combination isn't good, you know the user edited the xml file or copied the xml file from another installation. (On the other hand, using an xml file instead of say the registry, allows the user to simply uninstall the entire app and install it again. In any scenario, the xml files would all be recreated.)
You could also revert to confusion: name the tags you use for some other inconspicuous
object or setting that you are "checking".
Alternatively, or in combination, you could take the date you are recording now, take some other variable which value should be unique to this particular installation, or better even, the user's PC, and use them in some sort of formula, to create a code. Register the code somewhere else, and use it to retrieve the original installation date, and PC.
If you hadn't already thought of these yourself...
Good luck,
Johan
My advice is free, and you may get what you paid for.
|
|
|
|
|
I have the follow code in VB.NET 2005, i am trying to make it into a loop, is it possible, and if so, anyone fancy having a go at helping me at doing it, hints...etc?
The numbers of labels and text boxes goes from 1-10, so it will have to loop, then add 1 to the integer value, something like that!!! HELP!
CODE:
---
Priv Sub txtInput1_TextChanged(…) Handles txtInput1.TextChanged
If txtInput1.Text.ToLower = lblLetter1.Text Then
lblLetter1.ForeColor = R : intScoreAll += 1
Else
lblLetter1.ForeColor = W
End If
lblLetter1.BorderStyle = BorderStyle.None : txtInput1.Enabled = False
txtInput2.Enabled = True
lblLetter2.BorderStyle = BorderStyle.FixedSingle
txtInput2.Focus()
End Sub
---
|
|
|
|
|
You can use a foreach loop on the Controls collection and look for items by name or tag, or use dynamic type checking to work out which items are textboxes.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
I have a text file with the AE character in it when I try to read it with File.ReadAllText it does not read the character (it just removes it). I have tried File.ReadAllBytes(PATH/FILENAME.txt).replace(chr(198),"AE") and a couple other Replace ideas and so far nothing has worked. The only method I have found that works is:
Bytes = File.ReadAllBytes("PATH/FILENAME.txt")
For i = 0 To Bytes.Length - 1
TextFile += Chr(Bytes(i))
Next
This is horribly inefficient but does work...
Any better ideas?
|
|
|
|
|
Use the overload of the ReadAllText method that takes an encoding to specify the encoding that was used to create the file. Example:
text = File.ReadAllText(path, Encoding.UTF8)
---
single minded; short sighted; long gone;
|
|
|
|
|
hello evryone!!
m workin on fingerprint matchin algos nd hav selected the minutiae based approach.
the image enhancement,thinning nd stuff is done however m stuck on the pattern matching thing.
my code works on the pixel co-ordinates and pixel orientation approach, wherein i am confused as to how do i match the pixel cordinates as there is always a displacement problem in the input and the template image , evenif they have the same orientation
i am workin on vb.net 2003
|
|
|
|
|
You can't compare absolute coordinates, as the images you are comparing may be offset, scaled and rotated against each other. Express the relations between the coordinates as vectors, so that you can easily scale and rotate them when comparing them.
---
single minded; short sighted; long gone;
|
|
|
|
|
Hello!
I have one string value e.g (32765) and I would like to know how I can covert it to a color.
Dim myColor as Color
myColor = my.resources.FormBaseColor ' that is a string
Thanks for bunches!
What a curious mind needs to discover knowledge is noting else than a pin-hole.
|
|
|
|
|
The real question is, how do you *expect* 32765 to convert to a color ? If you mean it's an RGB value, you can use int.TryParse to get a number, and bit masking to extract the three values, which you can then turn into a color. So, 32765 && 0xFF, 32765 && 0xFF00, and 32765 && 0xFF0000 will get your three byte values.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
You can use the Color.FromArgb method to convert a number to a color. It expects a 32 bit value where there are eight bits each for alpha, red, green and blue.
If the value represents a color without an alpha value, you use FromArgb twice to set the alpha value. Example:
Dim c As Integer = &HFFFF00 'yellow<br />
Dim myColor As Color = Color.FromArgb(255, Color.FromArgb(c))
If your value represents a color in a different way, it may be simpler to extract the color components and create a color from that:
Dim myColor As Color = Color.FromArgb(red, green, blue)
---
single minded; short sighted; long gone;
|
|
|
|
|
Hello,
I know that there are many projects that show how to implement checking the md5 hash of a file in vb6 however I was not able to find any for vb.net can any one point me to the right direction ?
Thanks
Al968
Avast Antivirus-<url>http://www.avast.com<url>
|
|
|
|
|
Md5 is built into the System.Cryptography namespace. Therefore, no-one is going to write sample code to do it, the framework does it already.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|