|
Thanks Kevin
I use the Radio button to binding to field on the table
for ex :
on the table the user will choose between three cases ,
the method of Stock evaluation : choose on
1- FIFO
2- LIFO
3- Cost Average
I want to make the three choice as Radio button and binding it to the tree fields on database
i'm waiting your reply eagly
jooooo
|
|
|
|
|
That was pretty vague but if I understand correctly there are 3 fields in a table in the database, and you want to use the radio buttons to choose which field to select from?
<br />
dim Field as string<br />
IF rdb1.checked THEN<br />
field = 'field name<br />
else if rdb2.checked THEN<br />
field = 'field name 2<br />
else<br />
field = 'field name 3<br />
end if<br />
Thas pretty bad programing style but for purpose of explination it will suffice
Now you perform the select statement
<br />
SomeAdapter.SelectCommand.CommandText = "SELECT " & Field & " FROM some table WHERE somecontraints<br />
hope that helps
|
|
|
|
|
how can i develop a vb.net pocket pc application using oracle as the database?
isha
|
|
|
|
|
Does Pocket PC support Oracle ? If so, then just use it. if not, you can't.
Christian Graus - C++ MVP
|
|
|
|
|
If your pocket PC doesn't support Oracle, you will obviously need to host the database remotely, and access it from the PocketPC.
Aside from that, I don't know what type of answer you're wanting from "How can I develop a vb.NET...application". You can check out the Sytem.Data OleDB classes.
Jonathan Sampson
www.SampsonResume.com
|
|
|
|
|
how can i develop a vb.net smart device application using oracle as the database?
isha
|
|
|
|
|
Well, for starters you could start reading up on the OleDB objects in the System.Data.OleDB namespace. Here's an article that should give you a nice primer in VB.NET : http://www.startvbdotnet.com/ado/oracle.aspx
Jonathan Sampson
www.SampsonResume.com
|
|
|
|
|
i have to change the system date in vb.net,
i ll enter some date in the textbox and click on a button,the systemdate shud get chaged to watever date i have entered in the textbox
kavitha
|
|
|
|
|
I do not know if this is possible in vb, but you could shell to DOS and run the Date command i.e.
cmd /c date 20-11-06
This will work assuming you have rights to change the system date
Steve Jowett
|
|
|
|
|
hi everybody
i want dropdown menu like menu in form editor in vb 6.o from where we resize our controls,can anybody help me how i can make them.
Thanks
Thanks
|
|
|
|
|
Hey all again, i'm still doing that project, i figuired out how to do all the multiple forms and modules. But now i have a different problem.. Changing the menu colour... once again i need to be able to understand and reuse this code, i need to be taught. Thankyou very much
|
|
|
|
|
Tj. wrote: Hey all again, i'm still doing that project
Don't assume we have any idea what you're talking about Especially if it is relevant to your question. I am completely clueless as to what project you're doing
Tj. wrote: But now i have a different problem.. Changing the menu colour...
Can you be more descriptive? Which menu, which color? A font color, a background color, a border color, a highlighted color...
Jonathan Sampson
www.SampsonResume.com
|
|
|
|
|
i really need help or suggestion in my project proposal...
i have already a billing reports but the problem is that i don't know how to print it using visual basic.i dont know the code or the procedure to do it.
i look forward of your reply,thank you so much
|
|
|
|
|
Are you using VB.NET, or VB6 ? If you specify which one, and type the word 'print' as well, Google will tell you the answer.
Christian Graus - C++ MVP
|
|
|
|
|
Better you can use datareport or crystal reports for billing format.
|
|
|
|
|
hi!!!
thanks for that suggestion, but the problem is that i dont know the code or the procedure in printing the billing using datareport or crytal report.
any suggestions....thank you so much
|
|
|
|
|
Hi there....
I wrote a program under Visual basic to read pulses from a reed switch that i put it in my car, using parallel port.
I already put io.dll as mentioned in your site.
But when i tried it in my car the wiindow seem doesnt read it correctly.
I assume it was because it was windows dependence.
How do i make it less windows dependency?
in my program i simply write it like this:
Public Sub Timer3_Timer() * interval is 10
TerraGanti.Caption = PortIn(889)
End Sub
The program didnt catch up all the pulses correctly.
Please tell me how to fix it.
Thank u so much for helping me.
Best Regards,
Tegar Astarestu
|
|
|
|
|
vidante wrote: How do i make it less windows dependency?
I'm not sure what you mean. If you're using VB, you're dependant on Windows, no two ways about it.
Christian Graus - C++ MVP
|
|
|
|
|
I tried an commercial software for eletronic odometer, and it says that their software is less windows dependency, so it will read pulses from the reed switch on a wheel of the car correctly.
The software is run under windows. I think it was Visual C++.
What i am trying to do similar, counting pulses from a wheel, but it read the pulses as it wish, not as i wish....
You know, I've started a project, but I cant finish it.
You know how the feeling, right?
oh my....
|
|
|
|
|
vidante wrote: and it says that their software is less windows dependenc
Well, that's what we call 'marketing'
vidante wrote: What i am trying to do similar, counting pulses from a wheel, but it read the pulses as it wish, not as i wish....
As Dave said, if you're reading for pulses using a timed interval, you're not going to catch them all. Ideally, your hardware will cache the pules.
Christian Graus - C++ MVP
|
|
|
|
|
Well, part of your problem is that your polling the port. You're using a Timer that fires every 10 milliseconds and the PortIn function looks at the status of the port at that moment in time. If the switch is not making contact at that instant, it'll come back as not contacted. The port will not "buffer" the fact that, between polls, the contact was made and broken. In order to make sure the correct value is read, in your case, the switch must be held and making contact for at least 10ms (actually, even longer than that!), so that there is a wait for the next polling period.
The reason I say longer than 10ms is because your using a Form-based Timer, which is event driven. It fires an event approximately every 10ms, but that event can stay queued up in your applications message pump for much longer than 10ms, waiting for your code to get around to processing that event.
You'd be better off using one of the a thread-based timer and/or an A/D board for monitoring the switch. An A/D board would be a much better bet if your counting the number of times the switch is made and released on a per second basis, like counting RPM's of an axle...
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Thanks for the information.
But, since i am new in programming, i need more "lecture" on this.
What is a thread-based timer? How do i do it? Could you give me an example for he code?
It simply read a pulses from wheel of the car.
What is an A/D board? Is it Analog/Digital board?
Is it easy to make? If not, where can i get it?
From your explanation, i think an A/D board would fit.
How do i write the code to my project?
Thanks so much for helping me.
Regards,
|
|
|
|
|
Oh God...<sigh>
vidante wrote: It simply read a pulses from wheel of the car.
The problem is that the pulse doesn't exist long enough for your code to see it!
This REALLY needs specialized hardware. A timer, ANY timer, is just NOT going to do it. This hardware needs to respond to the event of the reed switch being tripped, not polled for it.
vidante wrote: What is an A/D board? Is it Analog/Digital board?
Yep. A board and specialized hardware that can do a much better job of counting these pulses than a parallel port can ever possibly hope to do.
vidante wrote: How do i write the code to my project?
That depends ENTIRELY on the board and it's software interface. Without knowing anything about it, there's no point in discussing any code.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hello,
I have to columns in my database table. Called scheduleTime and ScheduleDate.
When they are displayed in the datagrid they come out like the following: "21/11/06 10:45"
They displayed the date and the time.
The way I have inserted in the date and time, is to use shortDateformat, and localTime. However, it still displays it like the above.
If I was displaying the output in text boxes then I could format before displaying them in a text. However, as the output will be in a datagrid and the datagrid is binded at runtime is there any way to format the date to be: 21/11/06, and the time to be: 10:50
The code I use to populate the datagrid is below.
<br />
ds = objCustomersSupportContracts.getCustomerSupportContracts(clientID)<br />
Me.grdSupportContracts.DataSource = ds.Tables(0)<br />
Many thanks in advance,
Steve
|
|
|
|
|
Are you placing the grdSupportContracts(datagrid) on the form in design view?
|
|
|
|