|
Hello,
Does anybody have any idea about How to work with bar code machine and how to scan and get barcode in C#.Net.
Please provide me some code/Example resource.
Thanks in Advance.
|Muhamad Waqas Butt|
waqasb4all@yahoo.com
www.sktech.freewebspace.com
|
|
|
|
|
This is the 5th or 6th time I've seen this question this month.
Barcode scanners work either with a serial port or, more commonly, are connected to the keyboard port and act just like a second keyboard. Your application can't tell the difference between what is "typed" by the scanner and what is typed by the keyboard.
Normally, the focus is set to a control where the user then scans a barcode. The scanner "types" the information into this control, and so on...
Now, if you want to automatically set the focus so the user doesn't have to, you'll have to handle the keyboard events of the form. You'll have to program the barcode scanner (consult the scanner documentation on how to do this) to prepend and/or append a unique sequence of characters to every barcode it scans. You'll be looking for character combinations prepended and/or appended to the barcode key sequence in the form's keyboard handler events. When you see this combination, you'll have to change the focus to the appropriate control.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Well Thanks for your reply. I will try to search-out some resource for this. And if you know about something about it (for start programming) please inform me.
Thanks and best regards,
|Muhamad Waqas Butt|
waqasb4all@yahoo.com
www.sktech.freewebspace.com
|
|
|
|
|
The best resource you have is the manual on the scanner. When I did this, I spent about 10 minutes reading through the manual. After that, 60 seconds to write the first application and start scanning bar codes.
I learn best by doing...
|
|
|
|
|
Which Barcode Scanner you use and could you sends your piece of code?
Or
Can I download Barcode Scanner Manual from internet?
Thanks in Advance.
|Muhamad Waqas Butt|
waqasb4all@yahoo.com
www.sktech.freewebspace.com
|
|
|
|
|
Can someone shed some light on datagrid formating?
i have 2 requirements
1) Concatenate some fields - ie Address, Town, Zip
2) Set Column field widths
To achieve item 1) ArrayList of Objects is used - where each column is defined by a property.
To acheive item 2) I use a DataTable/DataView and GridColumnStyles
I have been unable to acheive both requirements. With a DataTable I cxannot perform the concatenate (without the use of views). I found some notes on "helper functions" but could only find information for ASP.Net datagrids.
With an ArrayList of Objects, I cannot set the column width because it seems to require a DataTable.
Any help is appreciated...
-- modified at 10:35 Wednesday 12th October, 2005
|
|
|
|
|
hi guyz,
is it possible to write / read image data to /from xml file?
I just've no idea.
Could anyone provide me with code/resource/guidance.
Thankx in advance,
Long Live
|
|
|
|
|
|
Hello,
How can I see the source code for an IRR function in Microsoft.VisualBasic namespace using the Reflector tool, any ideas?
Thank you.
|
|
|
|
|
Hi!
Here's the C# version of the code:
public static double IRR(ref double[] ValueArray, [Optional] double Guess )
{
double num5;
double num6;
int num11;
try
{
num11 = ValueArray.GetUpperBound(0);
}
catch (Exception)
{
throw new ArgumentException(Utils.GetResourceString("Argument_InvalidValue1", "ValueArray"));
}
... and so on...
} Start Reflector, open the file Microsoft.VisualBasic.dll (that's the assembly IRR is contained in, just read the documentation on the function to retrieve this information).
Navigate to the class Microsoft.VisualBasic.Financial and there you'll find IRR. Double click the function to see the decompiler window.
Regards,
mav
|
|
|
|
|
I can't navigate within the reflector to the Microsoft.VisualBasic.dll.
All I got is System.System.dll.Microsoft.VisualBasic etc.... How can I open Microsoft.VisualBasic.dll? How can I load assembly into the reflector?
Would you be able to post all of the code. Thank you very much.
-- modified at 9:14 Wednesday 12th October, 2005
I got it thanks again
|
|
|
|
|
My first choice would be to try File/Open, then go find the Microsoft.VisualBasic.dll file. A simple search of the hard drive for the filename reveals that it's in C:\WINDOWS\Microsoft.NET\Framework\version .
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
|
I found the way of looking up the code using Reflector.
You must go to File -> Cache..
Load the required assembly, and then access the IRR code.
I did add the reference to that assembly, I just really wanted to see how the method was implemented.
Thank you all!
|
|
|
|
|
If a user logs on such as "insert user name here" i want to play a sound "insert sound 1 here", but if a different user logs on, i want to play a different sound.
So can i check what user has loged on? or if a specific user has loged on?
|
|
|
|
|
Have you tried using System.Security.Principal.WindowsIdentity.GetCurrent() to return the WindowsIdentity for the current user? Then, use the Name property to get the user name. Then you can play the appropriate sound for that person.
Picture a huge catholic cathedral. In it there's many people, including a gregorian monk choir. You know, those who sing beautifully. Then they start singing, in latin, as they always do: "Ad hominem..."
-Jörgen Sigvardsson
|
|
|
|
|
Hello All
can any one help me where is the windows atom table and how to navigate it, and how to add and delete values from it
thx
|
|
|
|
|
|
|
let me explain , i want to navigate the atom table so i can able to find the record of the windows hotkey (win+D) and then unregister it , i had read before that this hotkeys values stored in the atom table,
i was trying the API unRegisterHotKey but i found that i must have the unique ID of that atom in the atom table
that is all
i hope if that topic is helpfull for all
and i hope if there any one can help me
thx
|
|
|
|
|
Hello,
After changing some content in my main-form and calling showDialog() for some input requirements i am totally losing the focus of the application. I don't have access to the menu, control boxes and ...
If i show this dialog bevore replacing some controls in my mainform everything works fine.
Anybody who can help?
Thanks
Frank
|
|
|
|
|
I've made a class containing an algorithm to make a query from MS Access. From a window form, i call to the class to make use of the method. In the first run, the result returns quite fast (130 records). But on any query after the first one, it runs VERY slowly. With only 130 records, it shouldn't be that slow. Is it because of MS Access or VS.NET 2005 Beta 2? I've tried to dispose all resources but it still doesn't work. What's going on here?
KiT
|
|
|
|
|
Dear all,
I have created an imagelist at runtime and am trying to fill it with images created at runtime.These images are of type Bitmap and are created based on the info from database.
Everything works fine but the problem is all the images in the imagelist are of the same color whereas it has to be be of different colors...here is my code...Any help would be appreciated.
/***********************************************************************************
iList myImageList;
FormLoad()
{
CreateImage();
myImageList = new ImageList();
if (myList.Count != 0)
{
foreach(Bitmap ic in myList)
{
myImageList.Images.Add(ic);
}
}
foreach (TwigCategory cat in m_TwigCategories)
{
this.cmb_CATEGORY.ImageList = myImageList;
Item = new ComboBoxExItem(cat.Description,0, cat.ID);
this.cmb_CATEGORY.Items.Add(Item);
}
}
private void CreateImage()
{
foreach (TwigCategory cat in m_TwigCategories)
{
Color color = ConvertRGB2Color((int)cat.RGB);
System.Drawing.Bitmap bmp = new System.Drawing.Bitmap(16, 16);
for (int x = 0; x < bmp.Height; ++x)
for (int y = 0; y < bmp.Width; ++y)
bmp.SetPixel(x, y, color);
for (int x = 0; x < bmp.Height; ++x)
bmp.SetPixel(x, x, color);
myList.Add(image);
}
m_TwigCategories.Reset();
}
private Color ConvertRGB2Color(int rgb)
{
int red = (int)rgb & 255;
int green = (int)((int)rgb / 256)& 255;
int blue = (int)((int)rgb / 65536) & 255;
Color color = Color.FromArgb(255, red, green, blue);
return color;
}
|
|
|
|
|
Could we get some sample rgb values for the ConvertRGB2Color method? Are you sure that your bit-twiddling is correct there?
Picture a huge catholic cathedral. In it there's many people, including a gregorian monk choir. You know, those who sing beautifully. Then they start singing, in latin, as they always do: "Ad hominem..."
-Jörgen Sigvardsson
|
|
|
|
|
Here are a few rgb values...the method works fine..the problem is actually with the imagelist..i get the same color for all the bitmaps
12583167
10551200
5767167
16734144
-8372160
|
|
|
|