|
I try. Though, sometimes, it's just hopeless.
|
|
|
|
|
Hi guys,
I've question
for example I wana to fill the data field for customer who wana to rent from my office (cars rental)
after that I need to save report or documnet PDF
how I can do that ????
|
|
|
|
|
Take a look at the documentation for MicrosoftReportViewer and the links in there.
Or if that is overkill, extract the fields from your data-entry form and do your own layout. (look at the Printer, PrintDocument and PrintPreview classes)
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.”
|
|
|
|
|
You can Use Report Viewer and Crystal report for Generating Report and Export it to PDF Format.
Best Regard
If you can think then I Can.
|
|
|
|
|
Hi
I need to add 3702 items in to a list box.. but unable to do it I guess maximum number of items that can be added is much less than this .. don't know exactly though..
But I need to some how allow the user to select one of 3702 items.Can any 1 suggest some solution . Please let me know asap.. I am using vb 2005
Thank u sooo much in advance
|
|
|
|
|
3702 is a big number, but not big enough to make a listbox crash. I think you should reconsider the design.
जय हिंद
modified on Friday, May 8, 2009 12:00 PM
|
|
|
|
|
Let's see your code, I think you are allowed to have tens of thousands of items in a listbox item collection, may be wrong but let's have a peek just to see.. I just ran a test
private void button1_Click(object sender, EventArgs e)
{
for (int i = 0; i < 4000; i++)
this.listBox1.Items.Add(i.ToString());
}
Added all items fine...
|
|
|
|
|
Hi,
If there is a limit it is much higher than 3702. What effect are you seeing when you try to add your items. Is there an exception?
Alan.
|
|
|
|
|
I didnt add them dynamically.. was adding them at design time.. i added abt 2228 states
then i cudn copy any more items in to the items property..
|
|
|
|
|
|
so maybe the property editor is what is the limiting factor.
anyway, I would never enter such an amount of data through a poor editor.
Why not:
1. enter it all in a file, then at run-time read that file (will be easier and faster); if need be, you can add the file as an internal resource
2. come up with a better user interface, people don't like scrolling thousands of items to find the right one.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Well.. it worked wen i populated it at run time..Thanks a lot
And about a different interface.. can u suggest any .. I am new to vb and dont know much abt the controls avaliable...
|
|
|
|
|
You're welcome.
suvigna wrote: an u suggest any
depends on circumstances, you should tell more about the application, what is in the list, how often one needs to select an item, how relevant adjacent items are, etc. And/or show say ten consecutive items.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Its for me to formulate a query.. Its a spatial query.
For example .. name all the hospitals in this city .. So when the user selects a city.. i.e., the city name.. i send it to the dbms to find all the hospitals in it.. and there is other processing done later
|
|
|
|
|
OK, then I would change it to a two-stage selection:
- first show all possible values for a category (e.g. by state/province, by first letter of name, by first two digits of zip code, whatever seems appropriate)
- then display the - much shorter - list of cities that belong to the chosen category
So if you come up with say 20 categories, the user would chose one, then select from an average of some 200 cities; much easier than scrolling through thousands of them.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
ok.. ya thanks.. will do that .. thanks alot
|
|
|
|
|
Yea, scrolling through thousands of items is insane..
Motivation is the key to software development.
|
|
|
|
|
So, you're populating all 3000+ cities in a single list?? How about adding another list that lets the user select a state, then you populate the city list with only the cities in the selected state?
|
|
|
|
|
Use multiple listboxes and sort alphabetically, listbox 1 would have all hospitals that begin with A-C, or you can subdivide based on region of a city, type of hospital. There are always different ways to categorize instead of dumping that much information.
|
|
|
|
|
I was attempting to build an analog clock for my computer. I've got the program just about finished, but I'm having a problem with the form's Invalidate() Function. When I run the program everything works fine for 5-6 seconds, but after that the form won't paint itself anymore. I've checked in debug mode and the loop is still running but the form doesn't paint. So I went a step further and forced the paint event under the mouse_doubleclick(). It is keeping time and the loop is running, but the form won't paint by itself.
I have a feeling that the problem is with something that XP is doing behind the scenes. Does anyone know how to solve this problem?
|
|
|
|
|
Adam Loudermilk wrote: Does anyone know how to solve this problem?
Looks like an hardware problem; in the device between the chair and the keyboard.
BTW what part of :
Please DO NOT POST PROGRAMMING QUESTIONS HERE. If you have a programming question please post it in the programming forums at forums.
you don't get?
Of all forms of sexual aberration, the most unnatural is abstinence.
|
|
|
|
|
Thank you for straightening that out for me. I'm new to programming and the CodeProject. It's always nice to have a friendly person show you the way.
Thanks for your help Diego Moita,
Adam
|
|
|
|
|
Oops and you thought you were in the Lounge
Unless of course the original post was in the Lounge and it was moved!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Hi, you'd better show some code, regarding the timer (initialization and tick handler) and possibly the paint handler (the essence of it, not all the graphic details).
|
|
|
|
|
I don't know how much you need (honestly I didn't think that any would be required to understand the problem). I've copied the timer tick() routine.
Private Sub ClockTimer_Tick(ByVal sender As Object, ByVal e As System.EventArgs) Handles ClockTimer.Tick
Me.Invalidate()
HourHand.Position = System.DateTime.Now.Hour
MinuteHand.Position = System.DateTime.Now.Minute
SecondHand.Position = System.DateTime.Now.Second
Application.DoEvents()
End Sub
When the program first starts to run the clock will tick about five times. Then it will pause for about 3 seconds, tick one more time and then it stops. I know that it is something that XP is doing, but I'm unsure of how to force it. I've also changed the styles of the form:
Me.SetStyle(ControlStyles.UserPaint Or ControlStyles.FixedHeight Or ControlStyles.FixedWidth Or _
ControlStyles.SupportsTransparentBackColor, True)
If someone has any idea what this might be I would appreciate you letting me know.
Thanks
|
|
|
|