Data Scraping on IE Web Message Pop-up


#1

Hi all,

I am using Data Scraping for a website. Every so often, the website sends a notification pop up e.g.:

Example Link with Popup

I have put in a parallel activity, and an “on element appears” function to close the pop up but it only works for the first time this pops up (on page 5), but on page 20, it pops up but doesn’t close the pop up. I’ve ensured it was a live selector too…

Any ideas?


1.1 Data scraping (Sequence)														
Private = False													
Variables													
	ExtractDataTable(DataTable)												
Activities													
	1.7 Attach Browser 'CouncilHo Page' (BrowserScope)												
		Selector = <html title='Council Houses 1 Crescent Royd Almondbury Huddersfield Social Ho*' />											
		BrowserType = IE											
		Private = False											
		Body											
			1.8 Do (Sequence)										
				Private = False									
				Activities									
					1.18 Parallel (Parallel)								
						Private = False							
						Variables							
							ele(UiElement)						
						Branches							
							1.9 Extract Structured Data 'TABLE' (ExtractData)						
								ExtractMetadata = <extract-table get_columns_name='1' get_empty_columns='1' />					
								MaxNumberOfResults = 0					
								DataTable = ExtractDataTable					
								NextLinkSelector = <webctrl css-selector='body&gt;div&gt;div&gt;div&gt;a&gt;i' idx='2' />					
								DelayBetweenPagesMS = 300					
								Target					
									Selector = <webctrl tag='TABLE' />				
									WaitForReady = COMPLETE				
								ContinueOnError = True					
								Private = False					
							1.10 On Element Appear 'iexplore.exe Message' (OnUiElementAppear)						
								WaitVisible = False					
								WaitActive = False					
								ContinueOnError = True					
								RepeatForever = True					
								Target					
									Selector = <wnd app='iexplore.exe' title='Message from webpage' /><ctrl name='Message from webpage' role='dialog' />				
									WaitForReady = NONE				
								Private = False					
								Body					
									1.12 Do (Sequence)				
										Private = False			
										Activities			
											1.15 Click 'Button' (Click)		
												KeyModifiers = None	
												CursorPosition	
													Position = Center
												SimulateClick = False	
												SendWindowMessages = False	
												ClickType = CLICK_SINGLE	
												MouseButton = BTN_LEFT	
												Target	
													Selector = <wnd app='iexplore.exe' title='Message from webpage' /><ctrl idx='1' name='Close' role='push button' />
													WaitForReady = INTERACTIVE
												Private = False	
	1.3 Write CSV (WriteCsvFile)												
		AddHeaders = True											
		FilePath = data3.csv											
		DataTable = ExtractDataTable											
		Delimitator = Comma											
		Private = False

#3

Hi,
You could you please attach selector attribute of on element appear activity?


#4

The “On element appear” selector is:

<wnd app='iexplore.exe' title='Message from webpage' />
<ctrl name='Message from webpage' role='dialog' />

The “Click Button” selector is:

<wnd app='iexplore.exe' title='Message from webpage' />
<ctrl idx='1' name='Close' role='push button' />

#5

ok cool so can you now get both selector field for page 20?


#6

No, it just stops and doesn’t do anything on that page, as if it doesnt see the element appear.


#7

is this same message box which appears in page 5?
Could you please use UiExplorer and get the selector of this popup message ?

If same give some delay in between and try.
Change WaitForReady to Complete
Play with WaitActive and Waitvisible

element


#8


Retrive tha data from pop up menu