|
I have set the "Release" configuration for a .NET solution.
Therefore, I expect that the solution will run in "Release" mode.
One problem - I have a third party dll attached and it is complaining about missing the following assembly - Microsoft.VC80.DebugCRT. It appears that Microsoft.VC80.DebugCRT is a "Debug" assembly that I wouldn't expect to get called while in "Release" mode.
So - If I set the "Release" configuration for a .NET solution then will this configguration also apply to any attached third party dlls?
|
|
|
|
|
No, because you don't BUILD your third party dlls, right ? You bought them and you're not building them are you ?
Make sure you copy the release version of the dll to the folder with your release build.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I am trying to install a merge module with the following command:
msiexec /a Microsoft_VC80_DebugCRT_x86.msm
My system displays a Windows Installer dialog that says - "Preparing to Install...". Then the dialog disappears.
After this, I go to C:\Program Files\Common Files\Merge Modules\ and the msm does not exist in the directory, although I am expecting it to.
What am I missing?
|
|
|
|
|
I added the merge module to a setup project and the merge module installed successfully.
Has anyone on this forum used msiexec to install merge modules? If so then please take a look at the command in my last post and let me know what might be wrong.
|
|
|
|
|
Ok, I've got this project which I've been developing for about 9 months now as a .NET web application. I was told today that we're switching gears and it's going to be a Windows app instead. Ok, slight problem. I know exactly two things about Windows app development, Jack and S**t. And guess what, Jack's just left town. So I throw myself upon the mercy of the gurus. Can anybody point me to a good tutorial on WinForms that talks about a multi-form application and using menus to switch between active forms. The only WinForm app ever developed by anyone at work was a small demo app that had two forms with a button on form 1 to hide form 1 and show form 2, then a button on form 2 to hide form 2 and show form 1.
I've tried googling for some tutorials and I'm coming up with nothing helpful. Anyone got any ideas?
|
|
|
|
|
Well, the main thing is, you just show a form by creating an instance of it and then calling ShowDialog or Show, depending on if you want it to be modal or not.
If your main form switches between forms, I'd create them as controls, put them all on the form, and swap which one is visible.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Christian Graus wrote: create them as controls, put them all on the form, and swap which one is visible
That's what the demo app I've got does. But this app is going to be a few hundred forms. It's going to be a replacement for four individual MS Access applications and we're rolling them all into one app as the departments that used them have been consolidated into one. I was hoping to be able to create a menu with some sort of method for showing/hiding controls and when the user clicks on a menu item that control shows and the currently visible one hides. Does that sound reasonable?
|
|
|
|
|
FyreWyrm wrote: Does that sound reasonable?
Yeah, the way I'd do that is, have an enum of forms, store the enum for the form you want in the tag, then write a method that you call which hides all forms, then shows the one specified by the enum value. So, you have one menu click event, which reads the tag, then turns it into an enum and calls one method that is always responsible for setting the visible form.
You can just iterate over the controls collection to hide your controls. You could even have the controls that are the forms have the same tag values so one function checks each controls tag and works out which one to show, no switch or anything needed.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Thanks Christian. I appreciate your help. I'm going to look into this more when I get to work tomorrow.
|
|
|
|
|
Cool - just post again if you get stuck.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Actually what you need is a WinForm with one main form and every form will be shown in the main form, one at a time, right?
You can create the forms as per normal, and instead of calling Show(), do the following instead. The form will be shown in the body of main form.
Form2 form = new Form2();
form.FormBorderStyle = FormBorderStyle.None;
form.TopLevel = false;
mainForm.Controls.Add(form);
form.Show();
|
|
|
|
|
Cool - so that basically adds the forms as controls, it's another path to what I was saying ?
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Yep, since it's a form as oppose to control, you can change it to MDI easily.
|
|
|
|
|
|
This seems nasty to me.
I think you need to string mash the table name, I don't think that's what parameters are for.
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Here is a snippet:
byte[] b = Encoding.Unicode.GetBytes("?"); // ? is a special (arabic) character,
// but my browser shows it as a ?.
string x = Encoding.Unicode.GetString(b);
While debugging, if I inspect my xx variable, I see a square as character. What did happened and why I did not see exactly the same character that the one I initialized b?
I write the a file, using the several encoding options available. When i read my file, I alway get this @#$%! of square character. But if I paste what I have in x in this message, I get --> "?"
I have a picture of it, but could not attache it
Thanks
modified on Thursday, May 15, 2008 8:33 PM
|
|
|
|
|
Assuming I've understood you right, the rectangle you're seeing is a representation of a character that is either unprintable, or one that isn't available in the font the Inspector is using (the latter reason is probably also why you got a ? instead of the expected character in your browser). It could also be because the inspector is interpreting the encoding wrong. I'd personally think the second cause is most likely.
To be honest, if the code works correctly (and I can see no reason why it won't if your snippet is anything to go by) I'd just ignore this 'feature' of Visual Studio, and use the clipboard and a decent text editor instead.
Hope this helps
Tony
|
|
|
|
|
Hello, I made a program in C# with a webrowser that loads a website. the website unfortunately has flash ads.
is it possible to block flash? or maybe stop the WebBrowser1 from loading <embed> tags? maybe change the embed tag to a div tag so that it doesnt show? how would i go about doing this? any help is appreciated. thanks
if it is too much to ask, i would appreciate some code? i already tried google with no success
modified on Thursday, May 15, 2008 7:46 PM
|
|
|
|
|
How do I get disk volume info in C#? (without having to traverse thru all dirs)
the same info as this function in C++:
GetDiskFreeSpaceEx(str, &lpFreeBytesAvailableToCaller,
&lpTotalNumberOfBytes, &lpTotalNumberOfFreeBytes );
Thanks.
mnnca
mnnca
|
|
|
|
|
You can use DllImport attribute to call GetDiskFreeSpaceEx from your C# code. This is for you to explore: P/Invoke[^]
By the way, DriveInfo Class[^] has quite many information about drives.
Giorgi Dalakishvili
#region signature
my articles
#endregion
modified on Thursday, May 15, 2008 5:43 PM
|
|
|
|
|
Thanks for the help.
I can't get the DllImport to work.
I don't know if it's because of my old IDE (2003).
I've installed up to .net frw 3.5.
System.IO still doesn't have the function "DriveInfo".
When I tried this:
[DllImport("user32.dll")]
public static extern bool ShowWindow(IntPtr hWnd, int nCmdShow);
the error is:
at "bool"
Expected class, delegate, enum, interface, or struct
why?
Thanks again.
mnnca
mnnca
|
|
|
|
|
DriveInfo class appeared in .Net Framework 2.0 so you need Visual Studio 2005 or later. As for GetDiskFreeSpaceEx pinvoke.net[^] can help you.
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
Thanks again.
I did try several DllImport code samples from PInvove. They all have the same syntax error.
I think it's my old IDE problem, it cannot open/run most of samples.
I'll need to buy the new .net version (if my boss can get budget for the whole sw group. doubt it!).
regards,
mnnca
mnnca
|
|
|
|
|
You can download Express version of VS2008 and try it there.
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
I dont have msdn subscription.
we're still using 6.0 (due to limitation of hardware device drivers, and users' hardware). We bought .net 2003 to learn it only.
mnnca
|
|
|
|