The easiest thing to do would be somthing like the following:
String test = "This is a test.";
System.Console.WriteLine(test.GetHashCode().ToString());
As the previous poster noted, you can't guarantee uniqueness when mapping from a larger domain to a smaller domain. But you may take comfort...
sorry guys, Im an idiot. Someone stuck a #ifdef in the middle of my file. None of the new functions were actually being compiled. Heres to stupidity at its finest.
Thanks for the help.
theres alot of code that was already working, but I'll include the relevent stuff....syntactically, I don't see anything missing...
//From parent header (ElectricComponent.h):
class ElectricComponent
{
public:
...
virtual void test();
...
};
//From parent (node.cpp):
#include...
I'm having a strange problem getting virtual functions to work... I get an "unresolved external symbol" error.
The virtual function is declaired and defined in the parent, and in one of the children it is overwritten.
If I simply move the overwritten function definition of the child into its...
Hi,
I've been tasked with converting very old excel macros to vba, as they are not supported by excel 2000. But to my surprise, they seem to work in excel 2003. Now have I gone crazy and am interpreting this wrong, or is 2003 really backwards compatible? Also, does anyone have a good...
is there a simple way to convert a gif to a bitmap? I haven't had alot of luck with the command line freeware stuff, and would prefer to do it directly in my script anyways.
yeah I had been trying to figure out what to do with that also... maybe I should give it another look. btw through a little experimentation, the filters also support gfa and png file formats, although I couldn't get the tiff filter to work. an odd collection I guess.
Hi,
I am trying to export an excel chart to a program that only accepts bitmaps, but haven't had much luck. What I've tried so far is the following...
ActiveChart.Export Filename:="e:\MyChart.bmp", FilterName:="BMP"
but apparently BMP isn't an acceptable filter. GIF and JPEG work ok (I...
Im trying to figure out how to use a hidden variable as an array, modifiable from the client side via javascript calls. What I would like to do is something similar to this this...
<input type="hidden" name="test[]" value="None">
<script type="text/javascript">...
Hi,
I'm a new C# programmer trying to figure out how to implement arrays of instances for classes I generate... I tried something that barfed like this:
bar [] foo;
public void initializefoo(){
for(int i=0; i<5; i++)
{
foo[i] = new bar();
}
}
I understand I might have to implement...
Im trying to modify text and links on a page without reposting to the server. I've been trying to use innertext to change a paragraph element with some success, but the links dont evaluate as html elements. Is there a good way to achieve this?
Example code:
<html>
<head>
<script...
I installed the SDK and documentation... I can see the Microsoft.DirectX DLL in the "C:\WINDOWS\Microsoft.NET\Managed DirectX\v9.05.132" directory... but when I try to reference the Microsoft.DirectX namespace using Visual C#, it complains that the reference cannot be found. What could I be...
Hi,
I'm trying to create a poster-sized document, and then print it (hopefully in sections that I can tape together) on a standard 8.5-11 printer. By default, it appears to try and shrink it to one page. Is there any way to set it up to do what I am asking?
Thanks
--werj
Hey,
Im trying to have a Fortran program link to a C program through a dll. I keep getting a invalid or corrupt file error when I compile the fortran. The C program is compiled as a dll in Visual C++ 6.0, the Fortran in Compact Visual Fortran 6.6a... Does anyone have a working example of how...
Im using vbscript to try and read all of the data on an excel sheet, without knowing the initial size or format. Is there a way to do a range call that grabs a range containing all the cells on a worksheet? Or preferably the minimum spanning range?
Hi,
Im new to javascript... so bare with me.
I wrote a depth first negamax search engine in C for a tic-tac-toe program, which I've been working on translating to javascript for my webpage, and I am confident that the algorithms in my javascript match those in my working C program. What I've...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.