|
i have serial jpeg codes, how to convert to bmp file?
And display bmp file?
|
|
|
|
|
Load them into a Bitmap object and then use the Save method. Yes it is as simple as that.
--------------------------------------------------------
My development blog
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
I don't understand that how to load jpeg code into a bimap object.
can you instantiate?;P
|
|
|
|
|
Everything you need is inside the Bitmap class.
Look it up on MSDN to see what methods are there for you.
--------------------------------------------------------
My development blog
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
using System.Drawing;
using System.Drawing.Imaging;
Image img=Image.FromFile(@"C:\image.jpeg");
img.Save(@"C:\image.bmp",ImageFormat.Bmp);
Graham
|
|
|
|
|
Can you convert this c# asp.net 2.0 html source code to vb.net please?
CssClass='<%# Eval("DepartmentID").ToString() == Request.QueryString["DepartmentID"] ? "DepartmentSelected" : "DepartmentUnselected" %>'>
|
|
|
|
|
it should be pretty similar
CssClass='<%# (DepartmentID.ToString() == Request.QueryString["DepartmentID"]) ? "DepartmentSelected" : "DepartmentUnselected" %>'>
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
|
|
|
|
|
This does not work in vb.net.
May be there should be iif
|
|
|
|
|
Sorry, my bad I misread your post and thought you asked for this to be converted from VB to C# - i now see you wanted th other way round.
So maybe it should use iif which is does like:
iif(condition,trueResult,falseResult);
try:
CssClass='<%# iif(DepartmentID.ToString() == Request.QueryString["DepartmentID"],"DepartmentSelected","DepartmentUnselected") %>'>
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
-- modified at 6:50 Friday 28th April, 2006
|
|
|
|
|
Yes, I am aware of the iif , but can not get the c# code to convert to vb.net
Thanks
|
|
|
|
|
VB uses = instead of ==.
---
b { font-weight: normal; }
|
|
|
|
|
is this ok?
CssClass='<%# (DepartmentID.ToString() = Request.QueryString["DepartmentID"]),"DepartmentSelected" : "DepartmentUnselected" %>'>
|
|
|
|
|
Where did iif go?
---
b { font-weight: normal; }
|
|
|
|
|
yes, I meant:
CssClass='<%# iif((DepartmentID.ToString() = Request.QueryString["DepartmentID"]),"DepartmentSelected" : "DepartmentUnselected") %>'>
Thanks
|
|
|
|
|
You never you colon to separate parameters for other functions. Why would you use it here?
---
b { font-weight: normal; }
|
|
|
|
|
May be it is best if you correct the whole code please.
Thanks
|
|
|
|
|
Did the extemely complicated change from a colon to a comma. Changed the brackets for Querystring to parentheses, as VB uses those.
CssClass='<%# iif((DepartmentID.ToString() = Request.QueryString("DepartmentID")), "DepartmentSelected", "DepartmentUnselected") %>'>
---
b { font-weight: normal; }
|
|
|
|
|
too late guffa posted the answer
Weve both given you different bits of this solution, but there comes a line where you must understand what you are writing, so that you learn. Its part of the learning curve that is learning how to program!
I'll give you another pointer, but i wont write the code for you this time.
The method you are trying to use is called iif . It takes three parameters. 1) The boolean condition to evaluate 2) the required return value if condition evaluates true 3) the required return value if condition evaluates false. These parameters are separated by a comma like this
iif(condition,trueValue,falseValue) .
The last code you posted had a incorrect character used to separate one of these parameters.
Now, that was a hell of alot of typing when i could have just given you the answer in 1 line... i hope you appreciate that!
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
-- modified at 9:29 Friday 28th April, 2006
|
|
|
|
|
ok, thanks
|
|
|
|
|
d'oh! this is why i usually dont write code in the VB forum - i'm too used to c#! Strange, in that i coded VB for more years than ive coded c#
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
|
|
|
|
|
how can i record voice and store it in files
record from the mic
|
|
|
|
|
|
Hi
I'm trying to auto-uninstall a COM service from componentservices with the help of Regsvcs.exe's /u command, but my code doesn't seem to work.
I have a deployment project, which in CustomAction/uninstall uses af custom install class to, among other things, unistall the service.
I have checked that my assemblypath(see code) is correct. I have tried to run Regsvcs /u from a command prompt, and the result is as expected - the service dissapears from the componentservices. When I use Regsvcs /fc during install via my custom install class it works. The service places itself nicely into componentservices. The only mysterious thing I can observe during the whole uninstallation process is, that the BeforeUninstall event seems to fire very late in the uninstall process.
Can anyone tell me, why this code whont delete the service from the componentservices?
<br />
private string regsvcsPath = Environment.GetEnvironmentVariable("windir") + @"\Microsoft.NET\Framework\v2.0.50727\regsvcs.exe";<br />
<br />
public CustomInstaller()<br />
{<br />
InitializeComponent();<br />
this.BeforeUninstall += new InstallEventHandler(CustomInstaller_BeforeUninstall);<br />
}<br />
<br />
void CustomInstaller_BeforeUninstall(object sender, InstallEventArgs e)<br />
{<br />
try<br />
{<br />
string parameters = @" /u " + this.Context.Parameters["assemblypath"];<br />
ProcessStartInfo psi = new ProcessStartInfo(this.regsvcsPath, parameters);<br />
Process.Start(psi);<br />
}<br />
catch (Exception ex)<br />
{<br />
MessageBox.Show(ex.ToString(), "Uninstall error");<br />
}<br />
}
|
|
|
|
|
i need to recode sound from the mic and paly it when i need
plz help me
it is part of my graduation project
Mayood
|
|
|
|
|
Did you even try searching the articles here?
Regards,
mav
--
Black holes are the places where god divided by 0...
|
|
|
|