|
You have to use the file info object to get the path of the file and then store it in the database.
Do good and have good.
|
|
|
|
|
Hello, I have a problem with 2 genereted wrapper DLL. This is my situation:
I have 2 software installed in the same directory that use Microsoft Web Browser (shdocvw.dll); those software when I compile generate 2 wrapper DLL (AxInterop.SHDocVw.dll and Interop.SHDocVw.dll). The problem is that the DLLs generated by first software are incompatible with the same generated by the second.
My idea is to change the name of the DLLs generated by the second software (Example: AxInterop.SHDocVw2.dll and Interop.SHDocVw2.dll), but here is the problem because this second is a C# software and seem that I can't change the DLL's name.
Can anyone help me?
Thank you very much
SD3
|
|
|
|
|
What I guess is the problem is that when you imported the COM object, it created a new interop dll in .NET with a different signature from the one of the second project. So while your first project is looking for the interop library with signature X, the second project is looking for the interop library with signature Y, that is why it doesn't work.
How to fix it? From the second project delete the references to SHDocVw. Now add a new reference in the second project, but select a .NET reference, and browse to your first project, and select from there the interop libraries.
Now both project use the same library with the same signature.
|
|
|
|
|
Hi all
i am a fresher in c#... my doubt is that when i open a form from another form i want that form to display on the center of the form from where i call ... i dont want to use mdi forms ... can anybody help me??
Thanks
Akhil
|
|
|
|
|
Form1 form1 = new Form1();
form1.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
|
|
|
|
Hi,
Form.StartPosition = FormStartPosition.CenterParent;
Robert
|
|
|
|
|
Wooowwww.... Thanx soo much
in the same way how will i do with messageBox ??? is there any way ???
thanx
Akhil
|
|
|
|
|
The first parameter of one of the Show method overloads on MessageBox is the owner window (IWin32Window to be exact - so control or form). The messageBox shows up centered over its parent, if passed.
|
|
|
|
|
i have created a custom scroll bar, and implemented the mousedown, mouseup etc. events. But -for instance- when i click and hold the down arrow the scrollbar value changes only once.
any ideas how to make the scrollbar scroll continuously when i click and hold up/down arrow ?
best regards...
.:: Something is Wrong ::.
|
|
|
|
|
You could try using a Timer. Start it when the mouse button is pressed and with every tick of the timer (perhaps after a delay) you change the scroll value a little. Stop the timer when the mouse button is released.
|
|
|
|
|
How can I use try and catch to catch errors on my application and write them in a lof file. eg logfile.txt
Boboza
|
|
|
|
|
try
{
throw new Exception("Error here");
}
catch(Exception ex)
{
StreamWriter streamWriter = new StreamWriter("logfile.txt", true);
streamWriter.WriteLine(ex.Message);
streamWriter.Close();
}
|
|
|
|
|
What I do is catch the error and write it to a custom eventlog.
I created a class that takes a string value(error.ToString()) and the type(error, warning, info).
Then in my catch I call the class with the parameters to write the eventlogentry and then just display a pretty message to the user.
You can do the same principle, except for a class that writes the an custom eventlog create a class that writes to a txt file.
He who laughs last is a bit on the slow side
|
|
|
|
|
Have a look at log4net[^]. It should cover (almost) anything you need regarding any kind of logging.
|
|
|
|
|
I am using a folder broswer dialog to let the user select a folder. The control is great, hoever i would only like the user to select a folder from the "C" drive - how do i do this? By default, all the folders are listed in it.
|
|
|
|
|
Hi All,
Can anyone please tell me if there's a way to use a .net application that
makes use of office 2003 interop assemblies on a server machine that does not
have office 2003 installed. The applcation creates .ppt files and there's no need
to actually view them on the server, so we don't need office 2003. On the other hand
the com components that the interop assemblies interface to are missing on the server.
Is there a manual way to copy the office com components and register them on the server?
Thanks very much
|
|
|
|
|
Even if it could be possible to find out which dlls are required to instantiate and operate the objects you want to use, I doubt that the office EULA will cover that.
Regards,
mav
--
Black holes are the places where god divided by 0...
|
|
|
|
|
hi all,
how will i know if a datagridview cell is left empty or not?
string.isnullorempty(dataGridView6.Rows[0].Cells[1].Value.ToString());
returns en error. [object reference not set to...]
any other method to check if empty or not ?
help please,
thanks in advance,
bye.
|
|
|
|
|
string s = dataGridView6[1,0].Value.ToString();
if (s != "")
{
.....
}
best regards
|
|
|
|
|
Hi,
I have a question about deployment project in C#. When we compile our project in c#. It generates two files one is perhaps setup and other is some thing called bootstrapper file. Now i want to know which of these two files is to be given to the user. I want the installer to install .Net and SQL Express if it is not installed on his machine already.
Thanks in advance...
Wasif Ehsan.
|
|
|
|
|
hi all,
i have a few things to ask about setup projects...
first, how can i add an uninstall option to User's Start Program.
second, how can i reinstall my setup even if a previous version was installed before ?
thanks in advance,
bye.
|
|
|
|
|
Firts one I'm not sure.
Second one, on the properties of your installer theres an option removePreviousVersions. Just set that to true
He who laughs last is a bit on the slow side
|
|
|
|
|
i want to write an application in c# that check either MSDE is installed on current machine to not if not then install MSDE on machine and copy SQL Server database (mdf and ldf) files to specific location so that my abouther c# application may use database could anybody help me out this please
|
|
|
|
|
I have the exact same problem. You can't use the installer within visual studio as it does not allow for multiple installation simultaniously.
So I started looking at external installers. Nice one to try is nullsoft installer, its freeware, you can be even include stuff like the runtime enviroment. You will just need to learn a bit about scripting so that you can manipulate the installer scripts as to what install when. They have alot of documentation and examples, so run through them, might even be able to mod one of the examples.
He who laughs last is a bit on the slow side
|
|
|
|
|
I made an c# application that uses SQL Server 2000 now i want to make a setup that not only installs my application but also MSDE to the clients machine so that my application can use database from MSDE how i would bmake that setup please help me out
|
|
|
|