Do WIA scan without calling IWiaDevMgr->DeviceDlg()

I am trying to do a wia scan using the  IWiaDevMgr, IWiaItem and

Created the IWiaDevMgr as in the following code
CComPtr<IWiaDevMgr> pWiaDevMgr
hr = pWiaDevMgr.CoCreateInstance(CLSID_WiaDevMgr);

then call the CreateDevice on that object with the correct device id

and then i call DeviceDlg on the pItemRoot
CComPtrArray<IWiaItem> ppIWiaItem;
hr = pItemRoot->DeviceDlg(

make IWiaDataTransfer using the ppIWiaItem
CComQIPtr<IWiaDataTransfer> pIWiaDataTransfer(ppIWiaItem[i]);

and call idtGetBandedData to do the scanning
hr = pIWiaDataTransfer->idtGetBandedData(

this code is working fine

But now i want to avoid the  pItemRoot->DeviceDlg call (I dont want to
display the default UI)

How can I do that? please help
2/10/2010 5:04:09 PM
development.device.drivers 941 articles. 0 followers. Follow

1 Replies

Similar Articles

[PageSpeed] 38

I found it we can use the IEnumWiaItem got by calling EnumChildItems
and enumarete the correct chiled item

see for
the implementation of the TransferWiaItem

(need to fix some bugs in the microsoft sample :) and implement the
CWiaDataCallback if you need implementation plz mail me)

CComPtr<IEnumWiaItem> pppIEnumWiaItem;
		if (SUCCEEDED(hr))
			ULONG fetched=0;
			ULONG celt=0;
			CComPtr<IWiaItem> pppIWiaItem;
					if (SUCCEEDED(hr))
						return hr;
2/17/2010 11:33:12 AM

Similar Artilces:

Service Call Tracking
I work for a service company that is driven by dispatched job numbers. I have created a "whiteboard" in Excel that I update daily, but it is very squished since I have 10 technicians that I track open jobs for. Is there a template out there that could help? The basic format of my whiteboard is: Date Dispatched Job # Tech Location/Notes Thanks. It is hard to answer such a question here. Could you send a sample sheet to me and I could devise a userform. it might be easier with textboxes or comboboxes or listboxes that have all your ranges on a form. The textboxes will ...

Auto Forward Rule without "FW"
I would like to setup a rule to auto forward a list of recipients without the "FW" tag in the subject line. I don't want to "Redirect", meaning I still want people to reply to me. I just don't want the "FW:" tag to appear in the subject line when the emails are forwarded. I am using Outlook 2003 Professional, not exchange. Can anyone assist? Thanks, Max you'd need to create a custom form and remove the FW from it then set it as the default form. -- Diane Poremsky [MVP - Outlook] Author, Teach Yourself Outlook 2003 in 24 Hours Coauthor, OneNo...

How to call a macro in an XLA add-in
Hello, This is an XLA newbie question (for Excel 2000)! I created an Excel addin (.xla type) with a macro in it and I installed the add-in. Then I opened another workbook, activated my VBA form and yes, there it was, my add-in. But now I want to create a macro in the workbook that calls a macro from the add-in (with parameters). How can I do that? My end goal of this is to create an add-in as a subroutine and function library for an extensive set of Excel sheets that need to be developed. Thanks for any help! This was just posted by Rob Bovey: Application.Run "'YourAdd-in.xla...

Doing a countif against a substring of the range to be scanned
I need to see how many cells in a particular range have a substring that matches the text against which I'm searching. So, for example, I've tried the following formula: COUNTIF(left(B2:B292,10),"="&left(cell("contents",P242),10)) I knew that this wouldn't work, but I was hoping that being able to evaluate the formula might lead me in the right direction. Excel won't accept the formula at all, though, so no chance to evaluate. I also tried this formula, which does let me evaluate: =COUNTIFS(B1:B292,"="&LEFT(P242,10)) ...

Formatting a Cell with a number without a decimal point
Version: 2008 Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel If I want to enter a number without a decimal point such as 523 I have to enter it as 523.00 and then set zero decimal places. No matter how I try to format it as 523 it either becomes 5.23, or is truncated to 5. <br> This only happens on some worksheets and might only occur in one column. What is wrong and how can I correct it? <br> Thanks in advance. <br> Alan Excel> Preferences> Edit, clear the box for "Display this number of decimal places". HTH |:>) Bob Jon...

What is the action called, when you lock headings
Or hold the column headings stationary while working way down on the sheet? I'd look it up myself in the helpfile, but don't see a description. Freeze panes. George Gee Stumpy wrote: > Or hold the column headings stationary while working way down on the > sheet? > I'd look it up myself in the helpfile, but don't see a description. Thanks. Now I got it. > > Freeze panes. > ...

Anybody familiar with an Add in call 411
Hello, I had on our system a Very nice tool call 411 Customer Search. But for some reason one day it just stop working. I check with our second store and it was also down. they whent down at the same time. it was not a tryout software. So I don't understand what could have happen to a very useful tool. If any body knows what happen please let me know. Thanks -- Reynold Cycle ...

How to call a MFC dll in C library
Hi all, I've write a C library to communicate with each other like ICQ, and wrote the UI by MFC on my library. But now I have a problem, I want to use HTTP connection in my library to download/upload buddy list or other files. After reading a lot of MSDN docs, I found it may be possible to wrap WinInet class as a dll and call it from my C library. But how shall I do it? Thanks! -- C.S.Chiang C compilers do not understand the decorated naming that is generated when C++ class member functions are exported. Therefore, you will need to create one or more C-like exported functions (...

Can you collect data into access 2007 using barcode scan guns?
Can you setup an access database to accept barcode scans? We are currently using tcp/ip for data collection into sql and wanted to know if Access 2007 can handle it? Yes, it can be done very easily. Scanners are simply I/O to the db so you can set them up to input data into a given control on your form just like a keyboard would. One reference on the subject can be found at -- Hope this helps, Daniel Pineault For Access Tips and Examples: Please rate this po...

Why do replies stay big without attachments?
I sent an Outlook message with a 3MB attachment. The addressee replied and we have bounced several replies back and forth. What is puzzling is that the messages seems to remain at a size of 3MB even though they have not had anything attached after I first sent it. No attachement is evident, but each one takes a long time to arrive and leave (and scan by Norton), attesting to their large size. What could cause this? Is there a way to strip the invisible attachment off? I can just delete past messages, but I'm thinking for any future replies, or when this happens again. I'd apprec...

System restrore without CD
I have such a problem, that I want to reinstall XP on my laptop, but unfortunately I don't have a CD which I would be able to boot from. Can anyone help me where can I download it or what to do? "sKUp" <> wrote in message > I have such a problem, that I want to reinstall XP on my laptop, but > unfortunately I don't have a CD which I would be able to boot from. Can > anyone help me where can I download it or what to do? Some laptops have SETUP or RESTORS rout...

Changing Numebers on Y Axis, without affecting Graph
I have a simple bar I created showing sites that have construction done. Is there anyway to have excel convert my data into a % (out of 100%) and graph my items? I do not want to do the math for each individual peice of data. Example: I have on peice of data that basically says 4 out of 5 were completed. How can I make excell chart that as 90%? Well, first of all, 4 out of 5 is 80%. Second, charts plot whatever is input. If you want to plot percentages, you have to calculate them, and plot the calculations. - Jon ------- Jon Peltier Peltier Technical Services, Inc. http://peltiertech.c...

Outlook 2007
I want to delete a meeting. I created and originated the Meeting Request. I wwant to remove it from my Calendar, without sending a notification or deleting the meeting from the other attendees calendars. How do I do so? What happens when you hit delete? Did you try moving it to the deleted folder? Note that if you do delete it without sending notification, you'll never be able to cancel the appointment, should it become necessary. -- Diane Poremsky [MVP - Outlook] Outlook Tips: Outlook & Exchange Solutions Center: http://www.slipstic...

Can I view an excell document without excell (not installed wit. #2
can I view an excell document without excell as it is not supplied with the XP home addition. ???????? Good evening You certainly can. Go here : for Excel Viewer 2003. HTH -- dominicb ------------------------------------------------------------------------ dominicb's Profile: View this thread: ...

Can one sort entries without due dates after entries with due dates?
I'm using Outlook 2007. I would like to sort all to-do entries without due dates AFTER entries that have a due date. When I define a sort order of descending due dates, Outlook sorts those without a due date to the end but of course also those that do have a date in reverse temporal order which I find useless. Using *ascending* due dates sorts those without a date first, which I find annoying. So, is there a way to tell it to sort "non-existing" higher than any real date? Michael ...

Changing Cell width without making the whole column that width?
Can someone please help? I'm trying to design a new spreadsheet fo work. In a column, I try to make a cell (say on row K) narrow, bu then the whole column goes to that same width. Is there a way to jus make a particular cell on a particular row narrow without making th whole column that width? Thanks. -Ke ----------------------------------------------- ~~ Message posted from ~~View and post usenet messages directly from You get all or nothing with column widths, you can use merged cells if that would help -- Paul B Always backup y...

edittext without border #2
anyone know how define edittext without border, i working with winapi on 98/xp that is edittext on DialogBox, has NOT WS_BORDER style thank you ...

Earn $200 per day without a website
Tired of wasting your time & hard earned money on "intelligent" programs which promise to make you rich overnight? Then read on, because I am going to show you............. How I made over $2000 in just 10 days using a ridiculously stupid technique I stole from my own affiliate Click the following link to see the entire procedure explained step-by- step. I Got MY Own ATM. J Wilson. ...

Call Workflow from Java / ASP.Net
Is there any way to call / start the workflow from either Java or an ASP.Net app? If so, does anyone have any basic examples? Take a look at the ExecuteWFProcess message in the SDK. From the SDK: // Create the request. ExecuteWFProcessRequest request = new ExecuteWFProcessRequest(); request.ProcessId = new Guid("{8DC95CE2-1A27-4CEA-9E6A-8F6BCC4B658D}"); request.EntityMoniker = new Moniker(); request.EntityMoniker.Id = createdId; request.EntityMoniker.Name = EntityName.account.ToString(); // Execute the request. ExecuteWFProcessResponse response = (ExecuteWFProcessResponse) servi...

Lookup without empty cells.
Currently my formula is b6 =VLOOKUP($C$4,Functions!$A3:$K$175,2,FALSE). I need the above formula in cells b7:b30. I do not want the blanks to show up if the formula is false. c4 is a month number, and the list Im searching in has multiple entries for the same month. I would like to show all entries for that month in cells b7:b30 and not have to go to b182. Can this be done? -- comotoman ------------------------------------------------------------------------ comotoman's Profile: View this thread: http://www.excelforum...

Error Http 413: entity too large calling web service on Win2003 Sr
We are calling a web service running in IIS 6.0 (Windows 2003 Server) When we call a web service method to send a large xml document (2Mb) obtain an http error 413 (entity too large) We have increase the web service reception size limit to 10Mb and still fails. Is there any limitation in the size of an xml document? Any idea? Thanks in advance. Pablo wrote: > We are calling a web service running in IIS 6.0 (Windows 2003 Server) > > When we call a web service method to send a large xml document (2Mb) obtain > an http error 413 (entity too large) > > We have increase t...

Printing Payroll Checks without Service
I have an accountant to handle all of my payroll tax issues, and I can calculate withholding, etc. on my own. I just want to be able to print a payroll check from Money 2005. Can this be done? It doesn't seem so to me. BTW I'm using Money 2005 Small Business. Thanks in advance for any assistance. ...

World Wide Calling! Unlimited Incoming Calls. #4
New virtual access anywhere technology lets you call anyone, anywhere in the world, from any phone! Access: ...

CSocket::OnReceive() not called
Hi all, My situation: - VC++ MFC application, Visual Studio .NET 2002 - Using CSocket derived class, isolated in separate thread (class treated as 'not thread safe') - Using CSocketFile and CArchive to do reads and writes - Using ::WaitForMultipleObject() with timeout to process window messages After a few hours OnReceive() is no longer called. I confirmed that data is actually sent across the wire and is also acknowledged by the TCP/IP stack using a network analyser. About half of the regular amount of messages is processed at the time of the problem. This clearly looks like an MFC...

Calling Default Handlers ?
Hi, I'm wondering if there are general guidelines in calling default handlers after handling the overridden message yourself. For example, OnChar() or OnHScroll(); it seems to work fine when I don't call the default at the end but maybe it's not doing something it should. Example: void CCustomEdit::OnChar(UINT nChar,UINT nRepCnt,UINT nFlags) { // I handle it here // is below really necessary ? CEdit::OnChar(nChar,nRepCnt,nFlags); } Robert A. wrote: >Hi, > >I'm wondering if there are general guidelines in calling default handlers >after handling the overr...