|
Barcode readers usually work exactly like a second keyboard. Unfortunately, you usually can't tell the difference between what is being types and what is being scanned.
That problem is easily solvable because most barcode scanners will let you specify a preamble and/or postamble so you can assume that whatever is comming between these characters is being scanned.
Your best bet is to get with the documentation on the scanner, open Notepad, then start playing with the barcodes you have to scan.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
How to create word/excel file in a Visual Basic Application ?
Thanks in advance
|
|
|
|
|
There's several articles in here regarding this.
Use the search to help you find them
|
|
|
|
|
hi all,
can anyone help me getting cleared with the following doubt?
i have a form with some input fields and i insert those values into a database and below the form i have a datagrid thro which i view the data which i added to the database i.e. all data that are present in the database.
but my problem is that, the data gets added but its getting repeated in viewing the datagrid.i tried using datagrid.refresh method it doesnt work . is there anyother method to view the data in the datagrid without getting repeated.kindly help me.
and i thank u in advance for ur effort.
|
|
|
|
|
Call
dataset.clear()method then call databind() method
|
|
|
|
|
Hi guys!
need urgent help...
i m developing an vb.net application. I want that during the installation of application the set up should check the pre-installed .net framework,
and if it is not present it should ask for the installation and install it if possible
Can any one help me!
abhinav
|
|
|
|
|
|
|
Hai,
I am beginners of vb.net.
I want to open word or notepad or any exe files through from the vb.net link.
How it is possible?
any body knows give some idea to me.
|
|
|
|
|
If nobody offers a better idea, this is how it was done in vb6. Perhaps you can use this as a starting point:
Private Declare Function ShellExecute Lib "shell32.dll" _
Alias "ShellExecuteA" _
(ByVal hwnd As Long, ByVal lpOperation As String, _
ByVal lpFile As String, ByVal lpParameters As String, _
ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
Private Const SW_SHOWNORMAL As Long = 1
Dim nResult As Long, pathName As String
pathname = <whatever you like>
nResult = ShellExecute(Me.hwnd, "Open", pathname , 0, 0, SW_SHOWNORMAL)
|
|
|
|
|
There is a method which runs .exe files or .bat files etc in vb.net.
System.Diagnostics.Process.Start(<give the="" path="" of="" exe="" file="">)
here the code try this
Add a linklabel to a form and on linkclicked event write this code
System.Diagnostics.Process.Start("notepad.exe") 'This would open a notepad
and if you want to open a WordPad. Then in place of "Notepad.exe" write "WordPad.exe"
-I Hope This Helps
... Pranjal
|
|
|
|
|
Thank u verymuch for ur timely help.
|
|
|
|
|
Sir,
Fine seeing ur reply immediately.its a great effort.
one more help please.i have form with some input fields and i insert those values into database and below the form i have a datagrid to which i view the data which add to database i.e. whole data that are present inthe database.
but my problem is the data gets added but its getting repeated in viewing the datagrid.i tried using datagrid.refresh method it doesnt work . is there anyother method to view the data in the datagrid without getting repeated.kindly help me.
and i thank u in advance for ur effort.
|
|
|
|
|
take a dataset fill it using a DataAdapter the assign this dataset to grid's datasource property.
When ever you save the data then first call dataset.clear() it would clear existing data in dataset, then refill the dataset using DataAdapter and reassign dataset to grids datasource.
this would prevent showing repetative entries in grid.
...Pranjal
|
|
|
|
|
Thank u verymuch for ur timely help
|
|
|
|
|
I have an Excel File in the directory: D:\Test.xls
the file has a worksheet "sheet1"
I want to name an user-defined range such as :
name: Myrange
range: sheet1!A1:F1
it's easy to operate it in the excel application
but i want to know how to use .Net code(VB.NET OR C#) to solve it?
i use oledb drive to connect an excel file,through the method GetOleDbSchemaTable()
i know that user-defined range is also consided to be a table type
but i don't know how to solve it using .net code
help me
work for living,work for interests,work for girlfriend
|
|
|
|
|
I have a project in VB6 that uses context menus that are dynamically created. I then use the index on the menu items to perform an action when the user selects it. If they select the 5th item I look at in internal array to do some processing. How can I do this in VB. NET I do not see a way to attach an index to the menu item in a context menu. I could have 20 menu items created dynamically and it could be a real pain to have to re-write all mu procedures to use names instead of indexes.
|
|
|
|
|
You have to use an array of MenuItem s. I don't know the exact VB.NET syntax, so I'll give you some C# code. Hopefully, you'll be able to understand it:
MenuItem[] contextItems;
...
contextItems = new MenuItem[2];
contextItem[0] = new MenuItem();
contextItem[0].Text = "Menu Item 1";
contextItem[1] = new MenuItem();
contextItem[1].Text = "Menu Item 2";
foreach(MenuItem item in contextItems)
item.Click += new EventHandler(ContextOnClick);
...
void ContextOnClick(object sender, EventArgs e)
{
int index = -1;
for(int i = 0; i < contextItem.Length; i++)
if(contextItems[i] == sender)
index = i;
if(index >= 0)
{
}
} I hope this helps!
-- LuisR
Luis Alonso Ramos
Intelectix - Chihuahua, Mexico
Not much here: My CP Blog!
The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005
-- modified at 16:55 Monday 12th September, 2005
|
|
|
|
|
Sorry for you but controls (like menuitems) do not support array indexing anymore. But that doesn't mean that there are newer (and better) ways of doing it. Here's a quick one.
Let's suppose the actions are stored in an array called act. Now assign to every menu item the "equivalent" index in the TAG property. Then hook all the click event to a single procedure:
private sub myclick(sender as object,e as...) handles menu1.click,menu2.click,...ecc
myaction=act(cint(ctype(sender,menuitem).tag))
end sub
Every menuitem click will go back to a single procedure (like in the array in VB6). By extracting the TAG field you can get the index (has to be converted from a string).
Hope it helps.
|
|
|
|
|
Thanks for your help, but I must still be missing something.
If I create a context menu there is no Tag field. But I wish to read the menu items from a file and add them dynamically to the menu at run time.
Now I have to have a procedure that handels that as you list an example private sub myclick(bla bla bla) handles menu1.click, menu2.click and so-on. Problem is I do not know what all teh different menus are at design time. So how do I do that?
signed
lost in menu *^*%^%&(, 2005
|
|
|
|
|
my fault I read normal menus rather then context, and I did not know that context menu miss the tag field. But since context menus are made of menuitems you should have the tag field available.
Anyway I give you another way of seeing at it.
When you have private sub x(sender as object,e as...) handles x.click,y.click,z.click
the sender paramter is the one that caused the event, in our case the clicked one. If you want to check it you can always do it this way:
if sender is x then
elseif sender is y then
elseif sender is z then
end if
if you have stricton you may have to cast sender to x object type.
|
|
|
|
|
Can someone tell me whats wrong with this code. Every time I execute it I get a "Operation must use an updateable query." error message. I have changed all the rights to the .mdb file so I am sure it isn't that.
I don't know if its the query itself, I may just have the wrong syntax.
HELP!!!
Public Function AddFixtures(ByVal HT As String, ByVal AT As String)
sConn = "Provider=Microsoft.Jet.OLEDB.4.0;"
sConn += "Data Source=C:\Inetpub\wwwroot\webapplication5\football.mdb;"
sConn += "Persist Security Info=False"
sCommAdd += "INSERT INTO Fixtures (Fixtures.HomeTeam, Fixtures.AwayTeam ) VALUES ('" + HT + "', '" + AT + "')"
oConn = New OleDbConnection(sConn)
oConn.Open()
oCommAdd = New OleDbCommand(sCommAdd, oConn)
oCommAdd.ExecuteNonQuery()
oConn.Close()
End Function
|
|
|
|
|
Two things...
First,
sCommAdd += "INSERT INTO
Are you really adding this string to something else? Keep in mind that Jet doesn't support compound statements.
Second, it's not enought to give the ASPNET account Write permissions to the file. You MUST give it Write permissions to the folder that the .MDB file is in. This is because Jet must create an .LDB file in the same directory so long as the database is opened. Without the ability to create that .LDB file, your request will fail with the error message you're getting.
PRB: ASP Returns 'Operation Must Use an Updateable Query' Error[^]
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Basically all I am trying to do is add a new row to my table in the database from an ASP.Net form.
My database has an
ID(Autonum), Date, String1, String2
So there is already data in there, so what I want is to add a new row in, for which it will automatically generate an Autonum.
At present of course I figure just to get it imputting the 2 strings. So I choose the 2 strings from List Boxes, and send them to my add function which I wrote above. And all I want that to do is add it to the end of the table generating an autonum.
I was thinking my syntax on the SQL statement was wrong.
-- modified at 18:35 Monday 12th September, 2005
|
|
|
|
|
First, Dave is right, you are adding to an existing command, when you should be creating a single command.
Second, it looks like you're adding the two strings only, does the date have a default value ?
Christian Graus - Microsoft MVP - C++
|
|
|
|