|
Hard to say!
If I COPY the class to a new file then I get error:
"The namespace 'X' already contains a definition for 'Y'".
But if I MOVE (or delete the original one) the class then I get a bunch of "could not be found".
Greetings - Gajatko
Portable.NET is part of DotGNU, a project to build a complete Free Software replacement for .NET - a system that truly belongs to the developers.
|
|
|
|
|
|
One more:
using X.Y;
namespace X
{
}
namespace X.Y
{
}
It looks like the file isn't included in the project anyway or sth like that
Greetings - Gajatko
Portable.NET is part of DotGNU, a project to build a complete Free Software replacement for .NET - a system that truly belongs to the developers.
|
|
|
|
|
One more remark:
These moved classes/namespaces ARE present in the Intellisense....
Greetings - Gajatko
Portable.NET is part of DotGNU, a project to build a complete Free Software replacement for .NET - a system that truly belongs to the developers.
|
|
|
|
|
Hello
How can i let the user chose the sever and the DataBase when the project is open
i mean how i can give the user the "Add Connection form" as he do when he want to Add Connection to the project,
he choose server and connect to the database so the form appear.
this what i want to do but by code and take the server name and the databas name from the Add Connection Form.
Thanks in advance
Assaf
|
|
|
|
|
|
Anyway Thank you for your help ...
Assaf
|
|
|
|
|
There is no one particular right way to do this. Like PIEBALD said, you'll have to create your own. Shouldn't be the tough. You'll need to have a way to store locally on the client machine the different connections, and other pertinent information needed for the connections.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I can do my own
But i want to call the one is called by the wizard where i choose the server and the database
and i can retreive then the name of each
My question can i do this by code ???
Thank you in advance
Assaf
|
|
|
|
|
Assaf82 wrote: i want to call the one is called by the wizard
Not sure if you can. It might be easier just to do your own
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
If it's even possible, the user would need to have Visual Studio installed to use your program.
---
single minded; short sighted; long gone;
|
|
|
|
|
Or will something like this help?
System.IO.FileInfo f = new System.IO.FileInfo ( "\\xt.udl" ) ;
f.OpenWrite().Close() ;
System.Diagnostics.Process p = System.Diagnostics.Process.Start ( "\\xt.udl" ) ;
p.WaitForExit() ;
System.Console.Write ( f.OpenText().ReadToEnd() ) ;
|
|
|
|
|
hi
How does one populate a grid with an array of objects?
this is the code for populatin a dropdown list control.
Author[] authorArray = dbComponent.GetAuthors();<br />
<br />
foreach (Author a in authorArray)<br />
{<br />
ListItem item = new ListItem();<br />
item.Text = a.FirstName + " " + a.LastName;<br />
item.Value = a.AuthorID;<br />
ddlAuthor.Items.Add(item);<br />
}
but i want to populate a grid control...
could anyone please help.
Thanks
|
|
|
|
|
Does this[^] article help?
/ravi
|
|
|
|
|
Yes, that is possible. Use the FileStream class to open the file, and use the Position property do decide where to read.
You will be reading bytes, of course, not characters.
---
single minded; short sighted; long gone;
|
|
|
|
|
I don't understand this, when I serialized my original index as 26 seperate hashtables, the index was only 1gig.
But just doing test runs with BinaryWriting and I shooting over 10gig easily on the same data.
Am I missing something here?
|
|
|
|
|
How are you serialising the data?
---
single minded; short sighted; long gone;
|
|
|
|
|
I had a busy form of which I had to copy, any idea why do I get this error..
Error 1 The item "obj\Debug\MySolutionFolder.My_Busy_Form.resources" was specified more than once in the "Resources" parameter. Duplicate items are not supported by the "Resources" parameter.
please help
Smile: A curve that can set a lot of things straight!
(\ /)
(O.o)
(><)
|
|
|
|
|
On this link.
Smile: A curve that can set a lot of things straight!
(\ /)
(O.o)
(><)
|
|
|
|
|
i need to dir all languages that in pc control panel in combobox to choose from it
i need quick answer
plz
thanks
md_refay
|
|
|
|
|
hi there,
i m reading a binary but it takes so long time to read, here is the codes
FileStream fs = new FileStream(@"D:\art1.bar", FileMode.Open);
BinaryReader br = new BinaryReader(fs);
string chk = "";
for (int a = 0; a < 4; a++)
{
chk += br.ReadChar().ToString();
}
int version = br.ReadInt32();
int unknown = br.ReadInt32();
byte[] uselessbytes = br.ReadBytes(264);
int unknown1 = br.ReadInt32();
int tnums = br.ReadInt32();
long dir = br.ReadInt64();
byte[] byts = br.ReadBytes(tnums);
br.BaseStream.Position = dir;
int dirnamelength = br.ReadInt32();
dirnamelength *= 2;
string dirname = "";
for (int a = 0; a < dirnamelength; a++)
{
dirname += br.ReadChar().ToString();
}
dirname = dirname.Replace("\0", "");
dirname = dirname.Replace("\\", "");
dirname = dirname.Replace(" ", "");
int numofFilesindir = br.ReadInt32();
for (int a = 0; a < numofFilesindir; a++)
{
dataGridView1.Rows.Add();
dataGridView1[1, a].Value = br.ReadInt32();
dataGridView1[2, a].Value = br.ReadInt32();
br.BaseStream.Position += 20;
int filelength = br.ReadInt32();
filelength *= 2;
string filename = "";
for (int b = 0; b < filelength; b++)
{
filename += br.ReadChar();
}
filename = filename.Replace("\0", "");
filename = filename.Trim();
filename.Remove(filename.Length - 3);
dataGridView1[0, a].Value = filename;
}
br.Close();
fs.Close();
it taking 15 seconds to read about 7000 files(i.e numofFilesindir = 7000)
i wanna know how can i reduce time or any alternative way that read fast
Becoming Programmer...
|
|
|
|
|
One reason is that you are concatening strings, this can become horribly slow inside loops, since each time a new string instance has to be created.
Use a StringBuilder instead and replace += with its Append method.
Also, you're reading the file byte by byte, why don't you read in all bytes at once an then convert the byte array to a string using the Encoding class?
regards
modified 12-Sep-18 21:01pm.
|
|
|
|
|
ok i ll use string builder, and tell you the result
Greeeg wrote: Also, you're reading the file byte by byte, why don't you read in all bytes at once an then convert the byte array to a string using the Encoding class
i cannot read in my format, its a file format of a game, thats why i have to read like that
Becoming Programmer...
|
|
|
|
|
xmen_xwk wrote: i cannot read in my format, its a file format of a game, thats why i have to read like that
7,000 files for a game?? A little excessive, don't you think?
|
|
|
|
|
its a archive file where about 7000 files stored, and there are about 8 or 9 more files like that have lots of files stored
i think you never edit any game...
Greeeg Use a StringBuilder instead and replace += with its Append method.
i tried it too but no benefit
-- modified at 13:29 Sunday 16th September, 2007
Becoming Programmer...
|
|
|
|