.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Easy Web
Imran Ghani
Post New Web Links

Capturing USB Barcode Scanner Return values

Posted By:      Posted Date: October 04, 2010    Points: 0   Category :Windows Application
 

Hi

We are using USB barcode scanner to scan material barcode labels. These lables are from our vendors.

We does not have control over the label generation. We are using USB barcode scanner for scanning purpose. We want to capture USB barcode scanner output. Normally the scanner returns output in the place holder in which the cursor present.

But we do not put writable text box for the cursor. Instead of write allowable text box we want to put locked or readonly text box in the screen and want to capture scanner value.

How can we do?

Assume that our barcode scanner does not support serial ports.

Regards
S. Muhilan


Muhilan


View Complete Post


More Related Resource Links

Writing Webservice return values to table within SQL CLR

  
Visual Studio 2010/Sql Server 2005/ .net 3.5/ C# I have compiled and created assemblies and all works fine when all I do is .pipe.send.   I have changed it now to capture the values in local parameters so I can write to a sql table on the same server.  I have the connection to the database and the table created.  The code compiles fine but when I run it from sql I get the following error.  The code follows the error.   Msg 6522, Level 16, State 1, Procedure CventSP, Line 0 A .NET Framework error occurred during execution of user-defined routine or aggregate "CventSP": System.Data.SqlClient.SqlException: Incorrect syntax near '@eventtitle'. System.Data.SqlClient.SqlException: at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnectionSmi.EventSink.DispatchMessages(Boolean ignoreNonFatalMessages) at Microsoft.SqlServer.Server.SmiEventSink_Default.DispatchMessages(Boolean ignoreNonFatalMessages) at System.Data.SqlClient.SqlCommand.RunExecuteNonQuerySmi(Boolean sendToPipe) at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at StoredP

Getting VP.NET code to respond to SQL Return values and Error Codes

  

I have SQL stored procedures that will return values depending on the outcome of its execution. I have the following code at the end of each of my Stored Procedures:

RETURN @siReturnValue

It would be great to be able to use this Return value after running the Stored Procedures from my VB.NET code. I have included an example of how I am running SQL Stored Procedures below:

    Public Function SearchKeyword(ByVal SearchString As String) As Data.DataTable
        Dim AerialConnection = New SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings("aerialConnectionString").ConnectionString)
        Dim MediaArchive As New Data.DataTable
        Dim reader As SqlDataReader
        
        Try
            AerialConnection.Open()
            Dim SelectMediaArchiveCommand = New SqlCommand("EXEC spSearch @keywords", AerialConnection)
            SelectMediaArchiveCommand.Parameters.AddWithValue("keywords", SearchString)
            reader = SelectMediaArchiveCommand.ExecuteReader()
            MediaArchive.Load(reader)
        Catch e As Exception
        Finally
            AerialConnection.Close()
        End Try
        Return MediaArchive
    End Function

How can I code this to respond to different Return values, or even error cod

encoding function parameters and return values when binaryMessageEncoding is used

  

Dear All,

I'm creating simple web service that will accept some parameters (such as customer name and file name) and return content of an xml file as a string and WS client will save it on his side. I'm using custom binding with binaryMessageEncoding and httpTransport. The question is if it is possible to have these input parameters as well as returned xml content binary encoded somehow?

Thanks in advance for your help!


Dzordz

Return a user and a set of values from the same sproc

  

I have a user table with userID, userName ...the standards.
I also have a "Material" table with materialID, materialName, etc.

I combine these in another table "UsersMaterial" with userID and materialID, depending on which materials the user has chosen (between 0 and 5).

Now I need a stored procedure that returns the user information + the set of materials that is mapped to the user.

But I can't see how I can return one row of user information combined with a set of the user materials? Do I join or can I return a set + one row?


Thanks in advance!

Niklas


How to Access MsiEnumRelatedProducts Return Values?

  

I am using the MsiEnumRelatedProducts function and according to all the articles I should be getting text return values such as:

ERROR_BAD_CONFIGURATION,
ERROR_NO_MORE_ITEMS

But I am only getting numbers returned from the function. I assume I need to use some Enum but I cannot find any example anywhere. I have looked at this article:

http://msdn.microsoft.com/en-us/library/aa370103(VS.85).aspx

But there is no explanation of how to actually get those text return values back?


Return values on VB.NET functions

  

I have been reading that a value needs to be returned by a function, otherwise the following error will occur:

"Function <function name> doesn't return a value on all code paths. A null reference exception could occur at run time when the result is used."

The cure, I have found, is to return something (i.e. "Return 0") before exiting the function. Can someone please enlighten me as to why this might be useful? Can I pass this return value back to the routine that called the function? If so, how do I code this?

Most of the time, however, I find I'm not needing to return a value anyway, and just end up adding "0" to the ends of all my Return statements. Does anyone have any comments on this?

Links referred to:

http://msdn.microsoft.com/en-us/library/87x5f80y%28VS.80%29.aspx
http://msdn.microsoft.com/en-us/library/2e34641s%28v=VS.80%29.aspx
http://forums.asp.net/p/1057272/1507771.aspx

Thanks!



return values

  

i'm trying to check if the text fields are blank i attached the code below, if i leave both textbox blank, both alerts pop up but confirm

how to make it like if the first textbox is blank, alert pop up then exit everything?

 function Validation()
{
if (IsValid()) {
  if (!(confirm("Are you sure you want to save this record?")))
  {
  return false;
  }
return true; 
}


function IsValid()
{
if (!isDate(document.getElementById('txtTest')))
{
alert("Please insert a Date");
return false;
}

if (!isBlank(document.getElementById('txtTest2')))
{
alert("Please insert a Holiday Name ");
return false;
}
return true;
}

asp:button onclientclick="return Validation()"


select query doesnt return values

  

hi all, i need your assistance please.

 

select Comments.Id,SuroundId,ArticleId,PosterId,PostRime,Subject,Body,Visible,Users.Username
from dbo.Comments
inner join Users on Comments.PosterId=Users.Id
where SuroundId=@suround and ArticleId=@articleId


for some reason it doesnt return any values.

before i've added the inner join it worked perfectly.

i couldn't find my mistake, though i passed over it several times.

 

thanks. 


Stored Procedures Only Return integer values?

  

I have the following stored procedure

ALTER PROCEDURE dbo.GetProvMoveModifier
	
	(
	@prov_id int 
	)
	
AS
	DECLARE	   @mod float
	SELECT     @mod = PROV_TYPES.MOVE_MOD
	FROM       PROV_DETAILS INNER JOIN
                      PROV_TYPES ON PROV_DETAILS.TYPE_ID = PROV_TYPES.TYPE_ID
	WHERE      (PROV_DETAILS.PROV_ID = @prov_id)
	RETURN     @mod


MOVE_MOD is defined as a float.


Yet within Dataclasses.designer.cs the function gets added as:

	[Function(Name="dbo.GetProvMoveModifier")]
	public int GetProvMoveModifier([Parameter(DbType="Int")] System.Nullable<int> prov_id)
	{
		IExecuteResult result = this.ExecuteMethodCall(this, ((MethodInfo)(MethodInfo.GetCurrentMethod())), prov_id);
		return ((int)(result.ReturnValue));
	}


Naturally this is causing some issues as my C# code needs to handle decimal values.  If I try to manually change the designer code to use floats, I get the following error

'System.Single' is not a valid return type for a mapped stored procedure method.


Any thoughts?  I could setup a work-around, but I would think I could return a decimal value from a stored procedure.


How to Pass Values Between Web Pages ASP.NET

  
You can pass information between pages in various ways, some of which depend on how the redirection occurs. The following options are available even if the source page is in a different ASP.NET Web application from the target page, or if the source page is not an ASP.NET Web page:

Use a query string.

Get HTTP POST information from the source page.

The following options are available only when the source and target pages are in the same ASP.NET Web application.

Use session state.

Create public properties in the source page and access the property values in the target page.

Get control information in the target page from controls in the source page.

How to Pass Values Between ASP.NET Web Pages

  
You can pass information between pages in various ways, some of which depend on how the redirection occurs. The following options are available even if the source page is in a different ASP.NET Web application from the target page, or if the source page is not an ASP.NET Web page:

Use a query string.

Get HTTP POST information from the source page.

The following options are available only when the source and target pages are in the same ASP.NET Web application.

Use session state.

Create public properties in the source page and access the property values in the target page.

Get control information in the target page from controls in the source page.

Free BarCode Software

  
Bar Code Specifications

There are more than 300 different types of barcodes, all with their own specifications. You will find detailed specifications of many popular bar code symbologies and where you can order the official specifications here at BarCode-1.

Barcode-1 Specification Sources Page list the most popular barcodes. It has links to technical information and is a good place to start.
The UPC/EAN Barcode Page lists the details of UPC barcode, and EAN barcode, the type used in grocery stores.
UCC128, EAN128 and GS1-128 Page lists the details for this important standard for marking shipping cartons.
The Code 39 Barcode Page has the details for Code 39 barcode, the most popular barcode used in industrial application.
The Code 128 Barcode Page has the details for Code 128 barcode, a barcode that can encode the entire ASCII character set.
The Interleaved 2 of 5 (I 2 of 5) Barcode Page has the details of this popular barcode.
The NW-7 Barcode Page has the details about this popular barcode in Japan.
The Plessey Code Barcode Page has the details for the historically important barcode.
The 2D Barcode Page lists the most popular two dimensional barcodes. It has links to technical information and is a good place to start if you a looking for 2D barcode information.

Use Camera as Barcode Reader

  
some important links

1)http://www.neodynamic.com/Products/Barcode-Compact-Framework/Barcode_Compact_Framework.aspx?tabid=90&prodid=6

2)http://www.quickmark.com.tw/En/basic/index.asp

The Free Barcode Creator produces barcode images one at a time, and allows easy saving to a file or

  
The Free Barcode Creator produces barcode images one at a time, and allows easy saving to a file or pasting into an application. 2D versions are also available:

jquery autocomplete multiple values

  

i got some samples and i did autocomplete using jquery , its working well for single input values

but i need to pass multiples values after one by one in the textbox. Is it possible to pass multiple

values in the textbox for autocomplete in jquery in asp.net?

 


ListView DataPager with SQL-Statements that already return only paged data.

  

Hi,

As far as I understand the ListView-Control and the DataPager-Control, they work like this: The ListView gets its datarows from its data source, then the DataPager causes the ListView to display only a subset of those rows.

So what, when I want to use custom databinding for the ListView, that *already* gets the certain subset from SQL-Server (for better performance). Can I and how can I use the DataPager then?

Thanx, S.


JQGrid Loading deleted values

  

Hi,

This is quite strange. here is the issue:

Some Info:

1. I'm using a multi-select jqgrid.

2. I have my own delete button to delete multiple orders

The problem:

When i press the delete button on the pager of my jqgrid, the records are deleted from the database but JqGrid shows some records (4-5). On refreshing the grid, correct numbers of records are shown.


Here is the code:


function delorder() {
        var amg = $("#horder").getGridParam('selarrrow');
        var cont = amg.length;
        if (amg.length > 0) {
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend