dickersonka 104 Veteran Poster

Not for sure of the way you are wanting to do this, but you are allowing 1-1 of army to infantry, archers, mounted knights, I'm assuming these are groups and not singles?

You might want to look at the longbows and cross bows. It looks like the distance is specified from the archer, and not for the weapon, which wouldn't allow these weapons to be different.

dickersonka 104 Veteran Poster

bill table should not have a primary key of patient
a patient will have multiple bills
that patient should not have a column of pbill, unless it something associated with the patient

move pbill to bill table
then you can have a patient with multiple bills, and i'm not sure why the employee is present, i don't see where you are relating it to anything

dickersonka 104 Veteran Poster

You might want to try it with user controls rather than forms. Create the user controls and add them to the panel.

If you really want forms, then take a look at MDI.

dickersonka 104 Veteran Poster

i would suggest to use a stored procedure to do all the calculations if you haven't already

declare num_days, price, temp_price int;

loop through your current time spans you have, and set price each time

set temp_price = select price from info where .....;

if your last select had a record then update price

set price = temp_price;

when you run into the date range you don't have, you don't update price and maintain the previous value

I'm not sure whether you are having a problem with the days portion or price portion, let me know if you need more assistance

dickersonka 104 Veteran Poster

Since there is a webservice in place. Download the file as a byte[], save it to the file system using System.IO.File. Then call Process.Start on the exe file, making sure to exit your program if it will be part of the files being updated.

dickersonka 104 Veteran Poster

I don't know what your method of calling the server is, or if it is local or remote. You might want to try a web service if you can't access the file publicly. If its public it can just be a url. In the C# code, you can reference a file as a byte array( byte[]). If you need further clarification, please supply a little bit more detail.

dickersonka 104 Veteran Poster

I'm sure you have already looked at obfuscation. That is about the best solution. If you are writing managed code, as in C#, it can be decompiled.

Here is a program that makes it harder than just plain obfuscation, but still doable, think its outdated now, but there might be something like it floating around.

http://www.remotesoft.com/salamander/protector.html

dickersonka 104 Veteran Poster

i think this is what you are meaning

select number, value from tablename where
number in (select number from tablename where value='foobar')

dickersonka 104 Veteran Poster

If you don't need the relationship, I would suggest moving the remarks back up the owning table.

If you do need the relationship, with the foreign key concept create a reference table.

student
STUDENT_ID
STUDENT_NAME

students2remarks
STUDENT_ID
REMARK_ID

remarks
REMARK_ID
REMARK

the table will can be used as a bridge in between the two

dickersonka 104 Veteran Poster

Not sure what part you have trouble with.
The concept would be loop through the results and add unique hosts to a list or hashtable and add the user to a list and each software to a list.
Then loop through the hosts, for each user in the host, for each user get software.

Create a tree node for each host, user, and software
set the child nodes of user equal to software, child nodes of host to user

dickersonka 104 Veteran Poster

To be sure its not permissions

use this at the top of filewatcher
[PermissionSet(SecurityAction.Demand, Name="FullTrust")]

also make sure dirinfo is a fully qualified path

and one last thing, why pass in the array to dirselected when you are only trying to poll the first folder

dickersonka 104 Veteran Poster

Interested to know, did you get your connection working?

dickersonka 104 Veteran Poster

Correct nvmobius, I'll add if you are doing this with more than just a simple example like that, might want to try this.

StringBuilder sb = new StringBuilder();
  sb.Append("sample");
  sb.Insert(0, "daniweb ");
  string s = sb.ToString();
dickersonka 104 Veteran Poster

Or you could just go the easy route

string s= "sample";
s = "daniweb " + s;
dickersonka 104 Veteran Poster

There will most likely be two permissions issues then.
There will be a permission to be allowed to connect to the database. Especially if you use integrated security.
The other will be the permission to use the connector, which most likely is fine if you use the .net one.
Try connecting in sql server management studio with that user and you'll most likely see the same results and appropriate troubleshooting message.

dickersonka 104 Veteran Poster

Definitely a permissions issue. When you say data dependency, do you mean database or file based?

dickersonka 104 Veteran Poster

The inner join on tb4 will only pull records that are in tb3 and tb4.
The query is also limiting tb2.language_code, so the query there is requiring every table to have the data regardless of the left join
I don't necessarily understand what you mean by security row, but the where clause with the inner join is the problem of limiting id's that will need to be present in all tables.

dickersonka 104 Veteran Poster

Try this solution. I have had the same issues with dev servers

http://blogs.sun.com/andreas/entry/no_more_unable_to_find

dickersonka 104 Veteran Poster

try Hide and Show for the form

//Hides 
Form.Hide();
//you can use this if you are in the form's code
this.Hide();

//Show the form
Form.Show();
//in the form's code
this.Show();
dickersonka 104 Veteran Poster

you need to initialize n

you can do this

int n = 0;