|
Hi
I am looking for a new way to licence our products. We currently ask the user to enter a company name, plus a load of parameters (such as package limits, number of users, expiry date, etc) which are then validated against an authorisation code we provide.
Each of our products have different parameters that relate to the functionality of that product, and as functionality increases, the number of parameters is also increasing.
Therefore, i am attempting to come up with a system that allows the user to enter just two bits of information, the Company Name and an Authorisation Code. The authorisation code is validated against the compan name and then the licence information is extracted out of the authorisation code.
It sounds great in principle, but i've no idea where to start on this, or if it is at all possible.
Any ideas or suggestions would be greatly appreciated.
Thanks
Tom
|
|
|
|
|
hi
i have a sqldb with unicode data column.(nvarchar)
i search the user data entry in textbox in webpage , in database.
please tell me how to convert string to utf8 charset?
thanks
|
|
|
|
|
Hello All,
I am writing an application using c#. This is a client server application. I am trying to make a login box which would allow users to enter the windows user id and password. Then I would like to check that user id and password against what the user id and password of who is login onto the machine. After that I would then like to check that user id and password against the sql server database to see if they have permission to access the database. Please someone provide guidance. I have looked everywhere and no one seems to have an answer to this question! Thanks
|
|
|
|
|
This is not good policy - If your users already log into Windows at the start of the session then you should consider that they have already passed through an authentication mechanism. Asking then to log on again during as session will desensitise them to providing a user name and password whenever prompted so that eventually they will do it automatically without thinking (that's how phishing scams work - they prey on the psycology of the person just following a set of instructions blindly - so don't encourage them for goodnesssake!).
Cada uno es artifice de su ventura
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and Forums
|
|
|
|
|
O.k. Thanks for your help
|
|
|
|
|
Friends,
I've been searching for a solution to a problem for 2 days on Google and forums but couldn't succeed. The problem is how do I get the ListView selection highlight style as it is in VS .NET menus. There is an article "TreeListView" here http://www.codeproject.com/cs/miscctrl/treelistview.asp[^] that has this feature but it's a little complicated for me to distinguish this feature from rest of the code.
This is my 3rd post on the same subject and will be the last - so please forgive me.
Thanks.
Radgar
"Imagination is more important than knowledge." - Albert Einstein
|
|
|
|
|
There is no such property. The control uses the system's Display Properties/Appearance colors to draw the highlights.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Dave, thanks for your time but I never said the control has the property. If it had, I'd never have asked this question, would I? The control can be inherited and/or custom-drawn via some Windows APIs or so.. I know it's possible and I gave a link of an example actually. But that example has too crowded code which is hard for me to pick the parts I need. Don't get me wrong but please read the post fully next time before answering because now my post seems like answered to other users who possibly has the correct solution I need.
Radgar
"Imagination is more important than knowledge." - Albert Einstein
|
|
|
|
|
Radgar wrote:
Don't get me wrong but please read the post fully next time before answering because now my post seems like answered to other users who possibly has the correct solution I need.
I did. The solution IS to ownerdraw the entire control and use the colors you want, not the system. If the example that you found is too much to wrap your brain around all at once, pick it apart. Try certain things and see what they do. Because nearly all of what you saw in the example is what your going to have to go through to get the functionality you want. The question you show now be asking yourself is "Is this worth it?"
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I need information about web pages that rent coders.
Thanks for your time
|
|
|
|
|
The Code Project isn't one of them. Thank you Chris!
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi,
I have two sockets and i want to transfer a struct object.How can i convert object to binary abd vice versa?Thanks for you time.
Wanna be C#
|
|
|
|
|
hii,that's too simple in c# first add Serializable attrubite before your struct
[Serializable]
struct YourStruct
{..}if struct also contains (nested) other structs objects. thier structs also must have Serializable attrubite then
using System.Runtime.Serialization.Formatters.Binary;
using System.IO
BinaryFormatter bin=new BinaryFormatter();
MemoryStream memory=new MemoryStream();
bin.Serialize(memory, yourStructObject);
byte[]data=memory.GetBuffer();//your struct in bytes
//to Reverse operation:
memory=new MemoryStream(data);
memory.Seek(0,System.IO.SeekOrigin.Begin);
yourStructObject=(YourStruct) bin.Deserialize(memory);
marcoryos
|
|
|
|
|
Thank u man..thanks a lot.That was simple and very specific
|
|
|
|
|
hii,i want to transfer a file from two hosts using Tcp protocol but the problem is i don't know the suitable transfer rate (the connection speed between those hosts)
felopater
|
|
|
|
|
|
The previous post is correct. Are you, perhaps, referring to the send and receive buffer sizes instead? That would reflect the largest "chunk" size that could be sent or received by the server and client.
If you're really referring to line speed then there's not a lot you can influence merely by using sockets or not.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’
|
|
|
|
|
I have a problem here with an exception.
<br />
try<br />
{<br />
... some code ...<br />
Exception appears here<br />
}<br />
catch(Exception ex)<br />
{<br />
... some code ...<br />
(go back into try block, but how ?)<br />
}<br />
After exception was thrown, application should continue code processing in the try block. Is it possible to avoid processing a special error with given error number ? Otherwise, code processing will be interrupted and application close this process.
|
|
|
|
|
you can try the following
public void HandleException( Exception ex )
{
... Do something, as in old catch ...
... some code ...
}
try
{
... some code ...
try
{
// Where exception appears
}
catch(Exception ex)
{
HandleException( ex )
}
}
catch(Exception ex)
{
HandleException( Exception ex )
}
CodeMadness - Code before you go mad!
|
|
|
|
|
Seraphin wrote:
application should continue code processing in the try block
Make your try blocks smaller.
So if you have
try
{
}
catch(Exception ex)
{
} Change it to:
try
{
}
catch(Exception ex)
{
}
try
{
}
catch(Exception ex)
{
}
try
{
}
catch(Exception ex)
{
}
Or a better solution would be to refactor your code so that item 1, item 2 and item 3 individual private methods that get called, each of which has their own try/catch block.
Does this help?
Cada uno es artifice de su ventura
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and Forums
|
|
|
|
|
|
A perfect example of when/why goto should NEVER be used! I haven't used GOTO since, what, 1992?
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Wow. I can't believe you would seriously suggest someone use this. Part of the advantage of methods written in a language like C, C++ or C# is that they are by nature "fall-through". No artificial flow interruptions, reroutes, twists, turns or gyrations are advised (such as "goto", "gosub" etc.).
This kind of coding reflects poor planning, not good practice. It looks like a (bad) piece of VB 6 code.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’
|
|
|
|
|
Maybe you should use IlDecompiler and look at the IL generated from some of your nice 'fall through' c# code. I think you'll find it is liberally sprinkled with goto's. The closer you get to the machine, the more useful and sensible goto gets to be.
what is gosub other than a void method call? is goto really any different than
if(true)<br />
...<br />
else<br />
...
I would agree that if-else is preferable for clatity: the brace blocks are clearer than a lable, but the result is no different: code branches to a new location under some conditions.
In leppies example, if there were multiple try-catch blocks in the same function, a goto and a common cleanup code block would be preferable for maintainability to repeating the code in each catch block...
Anger is the most impotent of passions. It effects nothing it goes about, and hurts the one who is possessed by it more than the one against whom it is directed.
Carl Sandburg
|
|
|
|
|
I was commenting on the code example provided. In the example, if an error is generated after the RESTART label, the code will loop indefinitely. That, to me, was a perfect example of why not to use the goto. It leads to bad code.
I'm not disputing whether IL contains goto calls. I am contending that at the time the IL is compiled, there are no nonsensical looping calls made if the developer has constrained him/herself to using the fall-through code style.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’
|
|
|
|