|
I tried the Visibile workaround... did not work. No controls have transparency as their backcolor. Any other suggestions?
|
|
|
|
|
perhaps someone can make a suggestion on how to convert this sample C code into c#?...
C code:
#include <time.h>
long Now;
struct tm *TimeStruct;
char *TimeString = "000000";
char LabelString[256];
TimeStruct = localtime(&Now)
sprintf(LabelString + strlen(LabelString),"%03d%d%04d",TimeStruct->tm_yday+1,TimeStruct->tm_year%10,Serial);
The issue is that I am working on the barcode command using c# and the variable to be:
string barCodeCommand;
I'm stumped on how to convert this into c# with the timestruct. I'm on with Serial variable.
|
|
|
|
|
|
Yes I do know DateTime.
but this portion of the code:
"%03d%d%04d",TimeStruct->tm_yday+1,TimeStruct->tm_year%10, Serial
I understand that means 3 digits of day and 1 digit of year and 4 digit of Serial
I dont understand why someone wrote: TimeStruct->tm_yday+1
^
/ \
+1? 3 digits for yday? that's the part I don't understand
|
|
|
|
|
tm_yday is Day-of-Year: ie Jan 1st is 001, Jan 31 is 031, Feb 1 is 032 etc. (Not sure what it does about Feb 29, / March 1, there are two ways of handling it depending on your industry). So, yes, tm_yday is three digits.
As for the "+1", that would be tomorrow, if tm_yday is today... Otherwise it's down to your code, I'm afraid.
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
tm_yday is the zero-based day of year i.e. January 1 = 0, January 2 = 1, and so on. The "+1" simply converts it to a one-based number.
Note that the DateTime.DayOfYear property is one-based so there is no need for the "+1" when converting to C#.
|
|
|
|
|
THANKS for the help. Now that clarifies up.. I will update my code.
|
|
|
|
|
Doh!
My bad!
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
Now that I've had success with the barcode printing. Thanks a heap again! I've learned something!
|
|
|
|
|
I want to insert an image in the word file through coding of C# 2008. Plz help urgently....
csetopper_bhanu
|
|
|
|
|
here is a code
App_Word.Selection.InlineShapes.AddPicture(Filename, ref MissingObj, ref MissingObj, ref MissingObj);
App_Word is object of Application
and Filename is a full name of file you wnat to add to word
Reg
Deep
Happy Coding!
|
|
|
|
|
You have asked this before. Also, "Plz help urgently" is considered very rude here.
only two letters away from being an asset
|
|
|
|
|
private void Form1_KeyDown(object sender, KeyEventArgs e)
{
MessageBox.Show(Convert.ToChar(e.KeyValue));
}
When typing - _ + = or anything like it, I keep getting a different strange characters!!
Please help.
ps. kc.ConvertTo(e.KeyCode,typeof(String)); doesnt work either
modified on Thursday, August 6, 2009 9:08 AM
|
|
|
|
|
Hello,
How we can hide an execution of progrmmes using :
<br />
Process rr = Process.Start("program path");<br />
Help me te resolve this great problem, Thank you verry mutch.
|
|
|
|
|
abbd wrote: How we can hide
What does that means?
A train station is where the train stops. A bus station is where the bus stops. On my desk, I have a work station....
_________________________________________________________
My programs never have bugs, they just develop random features.
|
|
|
|
|
Why do you need to hide the execution?
If you do not say, people are unlikely to help you.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Because i excute an auther programme generate my files, i would hide this MS-Dos window, beacause for any execution it's appear!!, thank you verry mutch.
|
|
|
|
|
Look up the documentation for ProcessStartInfo and ProcessWindowStyle
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Can you help me more? how i can use this?
thank you verry mutch.
|
|
|
|
|
Read the documentation. You clearly have not done so, you haven't had time.
There are plenty of examples there.
Clue: think about ProcessWindowStyle.Hidden
I will not write it for you. You have to do the work yourself.
If you need more examples then try Googling for .net hiding consolewindow
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
I try for :
<br />
Process rr = Process.Start("C:\\pgme.exe");<br />
rr.StartInfo.CreateNoWindow = false;<br />
rr.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;<br />
rr.WaitForExit();<br />
<br />
But unfortunately it not work, please help me, thank you verry mutch.
|
|
|
|
|
abbd wrote: rr.StartInfo.CreateNoWindow = false;
Try setting that to true. You've basically told it that you want it to create a window here.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys | Onyx
|
|
|
|
|
the same result, the window appear, can you help me? thank you verry mutch.
|
|
|
|
|
you're assigning StartInfo after you start the process. What happens if you do it this way:
Process rr = new Process("C:\\pgme.exe");
rr.StartInfo.CreateNoWindow = false;
rr.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
rr.Start();
rr.WaitForExit(); ?
|
|
|
|
|
There are an error, Process don't take 1 argument, thank you verry mutch.
|
|
|
|